title: After clear focus of edit text my other view got invisible in LG Optimus device
body: <p>On the click of reset button, I am resting all edit text and clearing the focus But this is working fine with other devices accept LG Optimus.
  In LG Optimus after press reset button and clearing the focus of current view, other view got invisible.I don't know why LG Optimus is behaving like that because same code is working fine in other devices.
  Before resting </p>
  
  <p><img src="https://i.stack.imgur.com/3638U.png" alt="enter image description here"></p>
  
  <p>after resting the edit text and clear focus.</p>
  
  <p><img src="https://i.stack.imgur.com/Vpfui.png" alt="enter image description here"></p>
  
  <pre><code>   OnClickListener reset_ClickListener = new OnClickListener() {
  
      @Override
      public void onClick(View v) {
          try {
              // TODO Auto-generated method stub
              getCurrentFocus().clearFocus();
              resetAllViews();
          } catch (Exception e) {
          }
      }
  };
  </code></pre>
  
  <p>And my resetALLViews() function is</p>
  
  <pre><code>    private void resetAllViews() {
      editTxtPiston.setText("");
      greyedOutTextField(editTxtPiston, false);
      editTxtRod.setText("");
      greyedOutTextField(editTxtRod, false);
      editTxtStroke.setText("");
      greyedOutTextField(editTxtStroke, false);
      editTxtPressure.setText("");
      greyedOutTextField(editTxtPressure, false);
      editTxtOilflow.setText("");
      greyedOutTextField(editTxtOilflow, false);
      editTxtAreaBore.setText("");
      editTxtAreaRod.setText("");
      editTxtVolumeBore.setText("");
      editTxtVolumeRod.setText("");
      editTxtForcrBore.setText("");
      greyedOutTextField(editTxtForcrBore, false);
      editTxtForceRod.setText("");
      greyedOutTextField(editTxtForceRod, false);
      editTxtTimeBore.setText("");
      greyedOutTextField(editTxtTimeBore, false);
      editTxtTimeRod.setText("");
      greyedOutTextField(editTxtTimeRod, false);
      editTxtVelocityBore.setText("");
      greyedOutTextField(editTxtVelocityBore, false);
      editTxtVelocityRod.setText("");
      greyedOutTextField(editTxtVelocityRod, false);
      editTxtOutflowBore.setText("");
      editTxtOutflowRod.setText("");
      editTxtRatio.setText("");
      settingsAllSpinnerToDefault();
      copy.setBackgroundResource(R.drawable.bg_disable);
      reset.setBackgroundResource(R.drawable.bg_disable);
      email.setBackgroundResource(R.drawable.bg_disable);
      copy.setEnabled(false);
      reset.setEnabled(false);
      email.setEnabled(false);
  }
      // greyed out edit text field
  private void greyedOutTextField(final EditText edit, boolean greyedOutState) {
      if (greyedOutState) {
          edit.setBackgroundResource(R.drawable.bg_darker_txt);
          edit.setClickable(false);
          edit.setCursorVisible(false);
          edit.setFocusable(false);
          edit.setEnabled(false);
          edit.setFocusableInTouchMode(false);
          edit.setInputType(InputType.TYPE_NULL);
          edit.setKeyListener(null);
      } else {
          edit.setBackgroundResource(R.drawable.bg_text);
          edit.setClickable(true);
          edit.setCursorVisible(true);
          edit.setFocusable(true);
          edit.setEnabled(true);
          edit.setFocusableInTouchMode(true);
          edit.setInputType(InputType.TYPE_NUMBER_FLAG_DECIMAL);
      }
  }
  </code></pre>
  
  <p>check this is my xml file</p>
  
  <pre><code>     &lt;ScrollView
      android:id="@+id/scrollView"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:layout_above="@+id/buttonView"
      android:layout_alignParentTop="true" android:fillViewport="true"&gt;
  
      &lt;RelativeLayout
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:background="#f9f9f9" &gt;
        &lt;!--On more Table layout is here and in this layout having edit text and  spinner--&gt;
          &lt;TableLayout
              android:id="@+id/tableLayout2"
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:layout_below="@id/side_header"
              android:layout_centerHorizontal="true"
              android:padding="4dp" &gt;
  
              &lt;TableRow
                  android:id="@+id/tableRow6"
                  style="@style/tablerow"
                  android:layout_width="match_parent"
                  android:layout_height="65dp"
                  android:layout_gravity="center_vertical" &gt;
  
                  &lt;ImageView
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_margin="2dp"
                      android:src="@drawable/area" /&gt;
  
                  &lt;TextView
                      style="@style/txt_for_backw"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:text="@string/area" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_bore_area"
                      style="@style/edit_for_gredout"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" &gt;
                  &lt;/EditText&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_rod_area"
                      style="@style/edit_for_gredout"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp"&gt;
                  &lt;/EditText&gt;
  
                  &lt;Spinner
                      android:id="@+id/spin_area"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".15"
                      android:entries="@array/array_metric_area" /&gt;
              &lt;/TableRow&gt;
  
              &lt;View
                  style="@style/divider"
                  android:layout_width="match_parent"
                  android:layout_height="1dp" /&gt;
  
              &lt;TableRow
                  android:id="@+id/tableRow7"
                  style="@style/tablerow"
                  android:layout_width="match_parent"
                  android:layout_height="65dp"
                  android:layout_gravity="center_vertical" &gt;
  
                  &lt;ImageView
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_margin="2dp"
                      android:src="@drawable/volume" /&gt;
  
                  &lt;TextView
                      style="@style/txt_for_backw"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:text="@string/volume" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_bore_volume"
                      style="@style/edit_for_gredout"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_rod_volume"
                      style="@style/edit_for_gredout"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;Spinner
                      android:id="@+id/spin_volume"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".15"
                      android:entries="@array/array_metric_volume" /&gt;
              &lt;/TableRow&gt;
  
              &lt;View
                  style="@style/divider"
                  android:layout_width="match_parent"
                  android:layout_height="1dp" /&gt;
  
              &lt;TableRow
                  android:id="@+id/tableRow8"
                  style="@style/tablerow"
                  android:layout_width="wrap_content"
                  android:layout_height="65dp"
                  android:layout_gravity="center_vertical" &gt;
  
                  &lt;ImageView
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_margin="2dp"
                      android:src="@drawable/force" /&gt;
  
                  &lt;TextView
                      style="@style/txt_for_backw"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:text="@string/force" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_bore_force"
                      style="@style/edit_side"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_rod_force"
                      style="@style/edit_side"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;Spinner
                      android:id="@+id/spin_force"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".15"
                      android:entries="@array/array_metric_force" /&gt;
              &lt;/TableRow&gt;
  
              &lt;LinearLayout
                  android:id="@+id/row8"
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:layout_gravity="center_horizontal"
                  android:background="#f9f9f9"
                  android:gravity="center_horizontal"
                  android:orientation="vertical" &gt;
  
                  &lt;ImageView
                      android:id="@+id/img81"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:src="@drawable/force_bore_side"
                      android:visibility="gone" /&gt;
  
                  &lt;ImageView
                      android:id="@+id/img82"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:src="@drawable/force_rod_side"
                      android:visibility="gone" /&gt;
  
                  &lt;ImageButton
                      android:id="@+id/swip_row8"
                      android:layout_width="match_parent"
                      android:layout_height="wrap_content"
                      android:background="@android:color/transparent"
                      android:src="@drawable/swipe_uparrow"
                      android:visibility="gone" /&gt;
              &lt;/LinearLayout&gt;
  
              &lt;View
                  style="@style/divider"
                  android:layout_width="match_parent"
                  android:layout_height="1dp" /&gt;
  
              &lt;TableRow
                  android:id="@+id/tableRow9"
                  style="@style/tablerow"
                  android:layout_width="wrap_content"
                  android:layout_height="65dp"
                  android:layout_gravity="center_vertical" &gt;
  
                  &lt;ImageView
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_margin="2dp"
                      android:src="@drawable/time" /&gt;
  
                  &lt;TextView
                      style="@style/txt_for_backw"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:text="@string/time" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_bore_time"
                      style="@style/edit_side"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_rod_time"
                      style="@style/edit_side"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;Spinner
                      android:id="@+id/spin_time"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".15"
                      android:entries="@array/array_metric_time" /&gt;
              &lt;/TableRow&gt;
  
              &lt;LinearLayout
                  android:id="@+id/row9"
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:layout_gravity="center_horizontal"
                  android:background="#f9f9f9"
                  android:gravity="center_horizontal"
                  android:orientation="vertical" &gt;
  
                  &lt;ImageView
                      android:id="@+id/img91"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:src="@drawable/time_bore_side"
                      android:visibility="gone" /&gt;
  
                  &lt;ImageView
                      android:id="@+id/img92"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:src="@drawable/time_rod_side"
                      android:visibility="gone" /&gt;
  
                  &lt;ImageButton
                      android:id="@+id/swip_row9"
                      android:layout_width="match_parent"
                      android:layout_height="wrap_content"
                      android:background="@android:color/transparent"
                      android:src="@drawable/swipe_uparrow"
                      android:visibility="gone" /&gt;
              &lt;/LinearLayout&gt;
  
              &lt;View
                  style="@style/divider"
                  android:layout_width="match_parent"
                  android:layout_height="1dp" /&gt;
  
              &lt;TableRow
                  android:id="@+id/tableRow10"
                  style="@style/tablerow"
                  android:layout_width="wrap_content"
                  android:layout_height="65dp"
                  android:layout_gravity="center_vertical" &gt;
  
                  &lt;ImageView
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_margin="2dp"
                      android:src="@drawable/velocity" /&gt;
  
                  &lt;TextView
                      style="@style/txt_for_backw"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:text="@string/velovity" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_bore_velocity"
                      style="@style/edit_side"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_rod_velocity"
                      style="@style/edit_side"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;Spinner
                      android:id="@+id/spin_velocity"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".15"
                      android:entries="@array/array_metric_velocity" /&gt;
              &lt;/TableRow&gt;
  
              &lt;LinearLayout
                  android:id="@+id/row10"
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:layout_gravity="center_horizontal"
                  android:background="#f9f9f9"
                  android:gravity="center_horizontal"
                  android:orientation="vertical" &gt;
  
                  &lt;ImageView
                      android:id="@+id/img101"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:src="@drawable/velocity_bore_side"
                      android:visibility="gone" /&gt;
  
                  &lt;ImageView
                      android:id="@+id/img102"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:src="@drawable/velocity_rod_side"
                      android:visibility="gone" /&gt;
  
                  &lt;ImageButton
                      android:id="@+id/swip_row10"
                      android:layout_width="match_parent"
                      android:layout_height="wrap_content"
                      android:background="@android:color/transparent"
                      android:src="@drawable/swipe_uparrow"
                      android:visibility="gone" /&gt;
              &lt;/LinearLayout&gt;
  
              &lt;View
                  style="@style/divider"
                  android:layout_width="match_parent"
                  android:layout_height="1dp" /&gt;
  
              &lt;TableRow
                  android:id="@+id/tableRow11"
                  style="@style/tablerow"
                  android:layout_width="wrap_content"
                  android:layout_height="65dp"
                  android:layout_gravity="center_vertical" &gt;
  
                  &lt;ImageView
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_margin="2dp"
                      android:src="@drawable/outflow" /&gt;
  
                  &lt;TextView
                      style="@style/txt_for_backw"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:text="@string/outflow" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_bore_outflow"
                      style="@style/edit_for_gredout"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_rod_outflow"
                      style="@style/edit_for_gredout"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp" /&gt;
  
                  &lt;Spinner
                      android:id="@+id/spin_out_flow"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".15"
                      android:entries="@array/array_metric_outflow" /&gt;
              &lt;/TableRow&gt;
  
              &lt;View
                  style="@style/divider"
                  android:layout_width="match_parent"
                  android:layout_height="1dp" /&gt;
  
              &lt;TableRow
                  android:id="@+id/tableRow12"
                  style="@style/tablerow"
                  android:layout_width="wrap_content"
                  android:layout_height="65dp"
                  android:layout_gravity="center_vertical" &gt;
  
                  &lt;ImageView
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_margin="2dp"
                      android:src="@drawable/ratio" /&gt;
  
                  &lt;TextView
                      style="@style/txt_for_backw"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:text="@string/ratio" /&gt;
  
                  &lt;EditText
                      android:id="@+id/txt_ratio"
                      style="@style/edit_for_gredout"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:textSize="14sp"/&gt;
  
                  &lt;EditText
                      style="@style/edit_side"
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".3"
                      android:visibility="invisible" /&gt;
  
                  &lt;Spinner
                      android:layout_width="0dp"
                      android:layout_height="wrap_content"
                      android:layout_weight=".15"
                      android:visibility="invisible" /&gt;
              &lt;/TableRow&gt;
          &lt;/TableLayout&gt;
      &lt;/RelativeLayout&gt;
  &lt;/ScrollView&gt;
  </code></pre>