Home
last modified time | relevance | path

Searched refs:mSeekBarPreference (Results 1 – 6 of 6) sorted by relevance

/packages/apps/Settings/src/com/android/settings/fuelgauge/batterysaver/
DBatterySaverScheduleSeekBarController.java52 public SeekBarPreference mSeekBarPreference; field in BatterySaverScheduleSeekBarController
57 mSeekBarPreference = new SeekBarPreference(context); in BatterySaverScheduleSeekBarController()
58 mSeekBarPreference.setLayoutResource(R.layout.preference_widget_seekbar_settings); in BatterySaverScheduleSeekBarController()
59 mSeekBarPreference.setIconSpaceReserved(false); in BatterySaverScheduleSeekBarController()
60 mSeekBarPreference.setOnPreferenceChangeListener(this); in BatterySaverScheduleSeekBarController()
61 mSeekBarPreference.setContinuousUpdates(true); in BatterySaverScheduleSeekBarController()
62 mSeekBarPreference.setMax(MAX_SEEKBAR_VALUE); in BatterySaverScheduleSeekBarController()
63 mSeekBarPreference.setMin(MIN_SEEKBAR_VALUE); in BatterySaverScheduleSeekBarController()
64 mSeekBarPreference.setKey(KEY_BATTERY_SAVER_SEEK_BAR); in BatterySaverScheduleSeekBarController()
65 mSeekBarPreference.setHapticFeedbackMode(SeekBarPreference.HAPTIC_FEEDBACK_MODE_ON_TICKS); in BatterySaverScheduleSeekBarController()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/widget/
DSeekBarPreferenceTest.java58 private SeekBarPreference mSeekBarPreference; field in SeekBarPreferenceTest
66 mSeekBarPreference = spy(new SeekBarPreference(mContext)); in setUp()
67 mSeekBarPreference.setMax(MAX); in setUp()
68 mSeekBarPreference.setMin(MIN); in setUp()
69 mSeekBarPreference.setProgress(PROGRESS); in setUp()
70 mSeekBarPreference.setPersistent(false); in setUp()
71 mSeekBarPreference.setHapticFeedbackMode(SeekBarPreference.HAPTIC_FEEDBACK_MODE_NONE); in setUp()
80 final Parcelable parcelable = mSeekBarPreference.onSaveInstanceState(); in testSaveAndRestoreInstanceState()
92 when(mSeekBarPreference.isDisabledByAdmin()).thenReturn(true); in isSelectable_disabledByAdmin_returnTrue()
94 assertThat(mSeekBarPreference.isSelectable()).isTrue(); in isSelectable_disabledByAdmin_returnTrue()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/batterysaver/
DBatterySaverScheduleSeekBarControllerTest.java41 mController.mSeekBarPreference = spy(mController.mSeekBarPreference); in setUp()
48 mController.onPreferenceChange(mController.mSeekBarPreference, 10); in onPreferenceChange_updatesSettingsGlobal()
52 assertThat(mController.mSeekBarPreference.getTitle()).isEqualTo(expectedTitle); in onPreferenceChange_updatesSettingsGlobal()
53 verify(mController.mSeekBarPreference).overrideSeekBarStateDescription(expectedTitle); in onPreferenceChange_updatesSettingsGlobal()
61 assertThat(mController.mSeekBarPreference.isVisible()).isFalse(); in updateSeekBar_routineMode_hasCorrectProperties()
62 verify(mController.mSeekBarPreference, never()).overrideSeekBarStateDescription(any()); in updateSeekBar_routineMode_hasCorrectProperties()
73 assertThat(mController.mSeekBarPreference.isVisible()).isTrue(); in updateSeekBar_percentageMode_hasCorrectProperties()
74 assertThat(mController.mSeekBarPreference.getTitle()).isEqualTo(expectedTitle); in updateSeekBar_percentageMode_hasCorrectProperties()
75 verify(mController.mSeekBarPreference).overrideSeekBarStateDescription(expectedTitle); in updateSeekBar_percentageMode_hasCorrectProperties()
84 assertThat(mController.mSeekBarPreference.isVisible()).isFalse(); in updateSeekBar_noneMode_hasCorrectProperties()
[all …]
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/display/
DBrightnessLevelPreferenceControllerTest.java48 private SeekBarPreference mSeekBarPreference; field in BrightnessLevelPreferenceControllerTest
68 mSeekBarPreference = new SeekBarPreference(mContext); in setUp()
73 PreferenceControllerTestUtil.assignPreference(mController, mSeekBarPreference); in setUp()
81 assertThat(mSeekBarPreference.getMax()).isEqualTo(GAMMA_SPACE_MAX); in testRefreshUi_maxSet()
90 assertThat(mSeekBarPreference.getValue()).isEqualTo(0); in testRefreshUi_minValue()
99 assertThat(mSeekBarPreference.getValue()).isEqualTo(GAMMA_SPACE_MAX); in testRefreshUi_maxValue()
108 assertThat(mSeekBarPreference.getValue()).isEqualTo( in testRefreshUi_midValue()
115 mSeekBarPreference.callChangeListener(0); in testHandlePreferenceChanged_minValue()
123 mSeekBarPreference.callChangeListener(GAMMA_SPACE_MAX); in testHandlePreferenceChanged_maxValue()
131 mSeekBarPreference.callChangeListener(convertLinearToGamma(mMid, mMin, mMax)); in testHandlePreferenceChanged_midValue()
/packages/apps/Settings/tests/robotests/src/com/android/settings/gestures/
DLabeledSeekBarPreferenceTest.java45 private LabeledSeekBarPreference mSeekBarPreference; field in LabeledSeekBarPreferenceTest
55 mSeekBarPreference = new LabeledSeekBarPreference(mContext, null); in setUp()
58 inflater.inflate(mSeekBarPreference.getLayoutResource(), in setUp()
67 mSeekBarPreference.setOnPreferenceChangeStopListener(mListener); in seekBarPreferenceOnStopTrackingTouch_callsListener()
68 mSeekBarPreference.onStopTrackingTouch(mSeekBar); in seekBarPreferenceOnStopTrackingTouch_callsListener()
70 verify(mListener, times(1)).onPreferenceChange(mSeekBarPreference, 2); in seekBarPreferenceOnStopTrackingTouch_callsListener()
/packages/apps/Settings/tests/robotests/src/com/android/settings/accessibility/
DBalanceSeekBarPreferenceTest.java44 private BalanceSeekBarPreference mSeekBarPreference; field in BalanceSeekBarPreferenceTest
49 mSeekBarPreference = new BalanceSeekBarPreference(mContext, mAttrs); in setUp()
52 inflater.inflate(mSeekBarPreference.getLayoutResource(), in setUp()
60 mSeekBarPreference.onBindViewHolder(mHolder); in seekBarPreferenceOnBindViewHolder_shouldInitSeekBarValue()