protected void updateView(View view){
  try {
    RelativeLayout layout=(RelativeLayout)view;
    mStatusText=(TextView)layout.findViewById(R.id.seekBarPrefValue);
    mStatusText.setText(String.valueOf(mCurrentValue));
    mStatusText.setMinimumWidth(30);
    mSeekBar.setProgress(mCurrentValue - mMinValue);
    TextView unitsRight=(TextView)layout.findViewById(R.id.seekBarPrefUnitsRight);
    unitsRight.setText(mUnitsRight);
    TextView unitsLeft=(TextView)layout.findViewById(R.id.seekBarPrefUnitsLeft);
    unitsLeft.setText(mUnitsLeft);
  }
 catch (  Exception e) {
    Log.e(TAG,"Error updating seek bar preference",e);
  }
}

protected void updateView ( View view ) { try { RelativeLayout layout = ( RelativeLayout ) view ; mStatusText = ( TextView ) layout . findViewById ( R . id . seekBarPrefValue ) ; mStatusText . setText ( String . valueOf ( mCurrentValue ) ) ; mStatusText . setMinimumWidth ( 30 ) ; mSeekBar . setProgress ( mCurrentValue - mMinValue ) ; TextView unitsRight = ( TextView ) layout . findViewById ( R . id . seekBarPrefUnitsRight ) ; unitsRight . setText ( mUnitsRight ) ; TextView unitsLeft = ( TextView ) layout . findViewById ( R . id . seekBarPrefUnitsLeft ) ; unitsLeft . setText ( mUnitsLeft ) ; } catch ( Exception e ) { Log . e ( TAG , "Error updating seek bar preference" , e ) ; } }
update a seekbarpreference view with our current state
