use of com.android.settings.applications.LayoutPreference in project android_packages_apps_Settings by DirtyUnicorns.
the class AccountHeaderPreferenceControllerTest method setUp.
@Before
public void setUp() {
MockitoAnnotations.initMocks(this);
FakeFeatureFactory.setupForTest(mContext);
mHeaderPreference = new LayoutPreference(RuntimeEnvironment.application, R.layout.settings_entity_header);
}
use of com.android.settings.applications.LayoutPreference in project android_packages_apps_Settings by DirtyUnicorns.
the class BluetoothDetailsButtonsControllerTest method setUp.
@Override
public void setUp() {
super.setUp();
mController = new BluetoothDetailsButtonsController(mContext, mFragment, mCachedDevice, mLifecycle);
mLeftButton = new Button(mContext);
mRightButton = new Button(mContext);
mLayoutPreference = new LayoutPreference(mContext, R.layout.app_action_buttons);
mLayoutPreference.setKey(mController.getPreferenceKey());
mScreen.addPreference(mLayoutPreference);
mLeftButton = (Button) mLayoutPreference.findViewById(R.id.left_button);
mRightButton = (Button) mLayoutPreference.findViewById(R.id.right_button);
setupDevice(mDeviceConfig);
when(mCachedDevice.isBusy()).thenReturn(false);
}
use of com.android.settings.applications.LayoutPreference in project android_packages_apps_Settings by crdroidandroid.
the class SettingsPreferenceFragment method setHeaderView.
protected void setHeaderView(int resource) {
mHeader = new LayoutPreference(getPrefContext(), resource);
addPreferenceToTop(mHeader);
}
use of com.android.settings.applications.LayoutPreference in project android_packages_apps_Settings by crdroidandroid.
the class StartNowPreferenceController method displayPreference.
@Override
public void displayPreference(PreferenceScreen screen) {
super.displayPreference(screen);
LayoutPreference pref = (LayoutPreference) screen.findPreference(getPreferenceKey());
Button startButton = (Button) pref.findViewById(R.id.dream_start_now_button);
startButton.setOnClickListener(v -> mBackend.startDreaming());
}
use of com.android.settings.applications.LayoutPreference in project android_packages_apps_Settings by crdroidandroid.
the class AccountHeaderPreferenceControllerTest method setUp.
@Before
public void setUp() {
MockitoAnnotations.initMocks(this);
FakeFeatureFactory.setupForTest(mContext);
mHeaderPreference = new LayoutPreference(RuntimeEnvironment.application, R.layout.settings_entity_header);
}
Aggregations