Remove non needed code for HeaderAdapter
- before, we were showing a Swich for WiFi and Bluetooth entries in the Headers. As this is no more the case, remove the code that is no more usefull. - as a side effect, we are also removing the call to update the Search Index that was running when the Settings app was resuming or pausing. Change-Id: I26b40df5c7a664d196a249840638d89909b6bc24
This commit is contained in:
@@ -614,7 +614,6 @@ public class SettingsActivity extends Activity
|
||||
mDevelopmentPreferences.registerOnSharedPreferenceChangeListener(
|
||||
mDevelopmentPreferencesListener);
|
||||
|
||||
mHeaderAdapter.resume(this);
|
||||
invalidateHeaders();
|
||||
|
||||
registerReceiver(mBatteryInfoReceiver, new IntentFilter(Intent.ACTION_BATTERY_CHANGED));
|
||||
@@ -632,8 +631,6 @@ public class SettingsActivity extends Activity
|
||||
|
||||
unregisterReceiver(mBatteryInfoReceiver);
|
||||
|
||||
mHeaderAdapter.pause();
|
||||
|
||||
mDevelopmentPreferences.unregisterOnSharedPreferenceChangeListener(
|
||||
mDevelopmentPreferencesListener);
|
||||
|
||||
|
@@ -262,14 +262,4 @@ public class HeaderAdapter extends ArrayAdapter<Header> {
|
||||
holder.mIcon.setLayoutParams(lp);
|
||||
holder.mIcon.setImageDrawable(icon);
|
||||
}
|
||||
|
||||
public void resume(Context context) {
|
||||
mWifiEnabler.resume(context);
|
||||
mBluetoothEnabler.resume(context);
|
||||
}
|
||||
|
||||
public void pause() {
|
||||
mWifiEnabler.pause();
|
||||
mBluetoothEnabler.pause();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user