title: Get value from CheckBoxPreference when it is changed
body: <p>I'm trying to create Preference Screen with a Checkbox control.</p>
  
  <pre><code> &lt;CheckBoxPreference android:summaryOn="@string/mySummaryOn" 
    android:summaryOff="@string/mySummaryOff" 
    android:key="myCB" 
    android:title="my checkbox"/&gt;
  </code></pre>
  
  <p>I want to get this Boolean value when ever its getting changed.</p>
  
  <p>In my Application i have done as below implementing OnSharedPreferenceChangeListener</p>
  
  <pre><code>public boolean cbValue;
   @Override
      public void onCreate() {
          // The following line triggers the initialization of ACRA
          ACRA.init(this);
          prefs=PreferenceManager.getDefaultSharedPreferences(this);
          prefs.registerOnSharedPreferenceChangeListener(this);
          super.onCreate();
      }
  
  public void onSharedPreferenceChanged(SharedPreferences sharedPreferences,
          String key) {
      // TODO Auto-generated method stub
      //FacebookStatus=prefs.getBoolean("myCB", true);
      Toast.makeText(getBaseContext(), "Shared Preference Changes ",Toast.LENGTH_LONG ).show();
  }
  </code></pre>
  
  <p>onSharedPreferenceChanged method is not at all called even when i toggle check box in pref screen.</p>
  
  <p>If i need to get value from Shared preference each time when value is changed wat should i do?</p>