Instantiate pref controllers from xml if it's defined.
- If a <preference> tag also defines a controller, we will try to instantiate it before displaying the UI. The same logic is shared by BaseSearchIndexProvider so it also drives search suppression. - If user also defines a list of controllers programatically, the programatically created ones takes precedence. Bug: 73668763 Test: WIP Change-Id: I7aecec270bcd3af261e012ef1f6995d2a523cfa1
This commit is contained in:
@@ -45,14 +45,18 @@ public class BluetoothDetailsMacAddressController extends BluetoothDetailsContro
|
||||
protected void init(PreferenceScreen screen) {
|
||||
mFooterPreference = mFooterPreferenceMixin.createFooterPreference();
|
||||
mFooterPreference.setTitle(mContext.getString(
|
||||
R.string.bluetooth_device_mac_address, mCachedDevice.getAddress()));
|
||||
R.string.bluetooth_device_mac_address, mCachedDevice.getAddress()));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void refresh() {}
|
||||
protected void refresh() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getPreferenceKey() {
|
||||
if (mFooterPreference == null) {
|
||||
return null;
|
||||
}
|
||||
return mFooterPreference.getKey();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user