Searched refs:mPolicy (Results 1 - 25 of 56) sorted by relevance

123

/packages/apps/Settings/src/com/android/settings/fuelgauge/batterytip/detectors/
H A DSummaryDetector.java28 private BatteryTipPolicy mPolicy; field in class:SummaryDetector
32 mPolicy = policy;
39 final int state = mPolicy.summaryEnabled
H A DLowBatteryDetector.java34 private BatteryTipPolicy mPolicy; field in class:LowBatteryDetector
39 mPolicy = policy;
51 && mBatteryInfo.remainingTimeUs < TimeUnit.HOURS.toMicros(mPolicy.lowBatteryHour));
54 if (mPolicy.lowBatteryEnabled) {
58 } else if (mPolicy.testLowBatteryTip || (mBatteryInfo.discharging && lowBattery)) {
H A DSmartBatteryDetector.java30 private BatteryTipPolicy mPolicy; field in class:SmartBatteryDetector
34 mPolicy = policy;
43 || mPolicy.testSmartBatteryTip;
H A DEarlyWarningDetector.java35 private BatteryTipPolicy mPolicy; field in class:EarlyWarningDetector
41 mPolicy = policy;
56 EarlyWarningDetector.class.getName()) || mPolicy.testBatterySaverTip;
60 : mPolicy.batterySaverTipEnabled && discharging && earlyWarning
H A DHighUsageDetector.java44 private BatteryTipPolicy mPolicy; field in class:HighUsageDetector
56 mPolicy = policy;
60 mDataParser = new HighUsageDataParser(mPolicy.highUsagePeriodMs,
61 mPolicy.highUsageBatteryDraining);
69 if (mPolicy.highUsageEnabled && mDischarging) {
71 if (mDataParser.isDeviceHeavilyUsed() || mPolicy.testHighUsageTip) {
91 if (mPolicy.testHighUsageTip && mHighUsageAppList.isEmpty()) {
100 Math.min(mPolicy.highUsageAppCount, mHighUsageAppList.size()));
H A DRestrictAppDetector.java42 private BatteryTipPolicy mPolicy; field in class:RestrictAppDetector
52 mPolicy = policy;
63 if (mPolicy.appRestrictionEnabled) {
/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/batterytip/detectors/
H A DSummaryDetectorTest.java37 private BatteryTipPolicy mPolicy; field in class:SummaryDetectorTest
44 mPolicy = spy(new BatteryTipPolicy(RuntimeEnvironment.application));
49 ReflectionHelpers.setField(mPolicy, "summaryEnabled", false);
50 SummaryDetector detector = new SummaryDetector(mPolicy, AVERAGE_TIME_MS);
57 SummaryDetector detector = new SummaryDetector(mPolicy, AVERAGE_TIME_MS);
H A DLowBatteryDetectorTest.java48 private BatteryTipPolicy mPolicy; field in class:LowBatteryDetectorTest
57 mPolicy = spy(new BatteryTipPolicy(RuntimeEnvironment.application));
60 ReflectionHelpers.setField(mPolicy, "lowBatteryEnabled", true);
61 ReflectionHelpers.setField(mPolicy, "lowBatteryHour", 3);
64 mLowBatteryDetector = new LowBatteryDetector(mContext, mPolicy, mBatteryInfo);
69 ReflectionHelpers.setField(mPolicy, "lowBatteryEnabled", false);
77 ReflectionHelpers.setField(mPolicy, "testLowBatteryTip", true);
H A DSmartBatteryDetectorTest.java43 private BatteryTipPolicy mPolicy; field in class:SmartBatteryDetectorTest
51 mPolicy = spy(new BatteryTipPolicy(mContext));
52 mSmartBatteryDetector = new SmartBatteryDetector(mPolicy, mContentResolver);
57 ReflectionHelpers.setField(mPolicy, "testSmartBatteryTip", true);
H A DEarlyWarningDetectorTest.java46 private BatteryTipPolicy mPolicy; field in class:EarlyWarningDetectorTest
59 mPolicy = spy(new BatteryTipPolicy(mContext));
67 mEarlyWarningDetector = new EarlyWarningDetector(mPolicy, mContext);
72 ReflectionHelpers.setField(mPolicy, "batterySaverTipEnabled", false);
81 ReflectionHelpers.setField(mPolicy, "testBatterySaverTip", true);
H A DHighUsageDetectorTest.java71 private BatteryTipPolicy mPolicy; field in class:HighUsageDetectorTest
80 mPolicy = spy(new BatteryTipPolicy(mContext));
81 mHighUsageDetector = spy(new HighUsageDetector(mContext, mPolicy, mBatteryStatsHelper,
109 ReflectionHelpers.setField(mPolicy, "highUsageEnabled", false);
116 ReflectionHelpers.setField(mPolicy, "highUsageEnabled", true);
126 ReflectionHelpers.setField(mPolicy, "testHighUsageTip", true);
/packages/apps/Settings/src/com/android/settings/notification/
H A DZenModeBackend.java49 protected NotificationManager.Policy mPolicy; field in class:ZenModeBackend
72 mPolicy = mNotificationManager.getNotificationPolicy();
105 return (mPolicy.suppressedVisualEffects & visualEffect) != 0;
109 return (mPolicy.priorityCategories & categoryType) != 0;
113 int priorityCategories = mPolicy.priorityCategories;
124 return mPolicy.priorityCallSenders;
132 return mPolicy.priorityMessageSenders;
142 savePolicy(mPolicy.priorityCategories, mPolicy.priorityCallSenders,
143 mPolicy
[all...]
H A DZenFooterPreferenceController.java36 return mBackend.mPolicy.suppressedVisualEffects == 0
37 || Policy.areAllVisualEffectsSuppressed(mBackend.mPolicy.suppressedVisualEffects);
44 if (mBackend.mPolicy.suppressedVisualEffects == 0) {
46 } else if (Policy.areAllVisualEffectsSuppressed(mBackend.mPolicy.suppressedVisualEffects)) {
H A DZenModeVisEffectsCustomPreferenceController.java74 Policy.areAllVisualEffectsSuppressed(mBackend.mPolicy.suppressedVisualEffects);
75 boolean noEffectsSuppressed = mBackend.mPolicy.suppressedVisualEffects == 0;
/packages/services/Car/service/src/com/android/car/
H A DBluetoothAutoConnectStateMachine.java42 private final BluetoothDeviceConnectionPolicy mPolicy; field in class:BluetoothAutoConnectStateMachine
61 mPolicy = policy;
131 mPolicy.connectToDeviceOnProfile(BluetoothProfile.PBAP_CLIENT, device);
132 mPolicy.connectToDeviceOnProfile(BluetoothProfile.MAP_CLIENT, device);
153 boolean deviceToConnectFound = mPolicy.findDeviceToConnect();
198 mPolicy.updateDeviceConnectionStatus(params, false);
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/
H A DZenFooterPreferenceControllerTest.java84 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0);
90 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2);
105 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, allSuppressed);
111 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0);
118 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2);
134 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, allSuppressed);
H A DZenModeVisEffectsCustomPreferenceControllerTest.java93 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0);
99 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 1);
106 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 0);
123 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, allSuppressed);
131 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2);
139 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 2);
H A DZenModeBlockedEffectsPreferenceControllerTest.java46 private NotificationManager.Policy mPolicy; field in class:ZenModeBlockedEffectsPreferenceControllerTest
59 when(mNotificationManager.getNotificationPolicy()).thenReturn(mPolicy);
H A DZenModeBehaviorCallsPreferenceControllerTest.java48 private NotificationManager.Policy mPolicy; field in class:ZenModeBehaviorCallsPreferenceControllerTest
61 when(mNotificationManager.getNotificationPolicy()).thenReturn(mPolicy);
H A DZenModeBehaviorMsgEventReminderPreferenceControllerTest.java48 private NotificationManager.Policy mPolicy; field in class:ZenModeBehaviorMsgEventReminderPreferenceControllerTest
61 when(mNotificationManager.getNotificationPolicy()).thenReturn(mPolicy);
H A DZenModeBehaviorSoundPreferenceControllerTest.java48 private NotificationManager.Policy mPolicy; field in class:ZenModeBehaviorSoundPreferenceControllerTest
61 when(mNotificationManager.getNotificationPolicy()).thenReturn(mPolicy);
H A DZenModeVisEffectsAllPreferenceControllerTest.java100 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 1);
117 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, allSuppressed);
134 mBackend.mPolicy = new NotificationManager.Policy(0, 0, 0, 1);
/packages/apps/Email/src/com/android/email/activity/setup/
H A DSetupDataFragment.java54 private volatile Policy mPolicy; field in class:SetupDataFragment
66 mPolicy = null;
81 outState.putParcelable(SAVESTATE_POLICY, mPolicy);
96 mPolicy = savedInstanceState.getParcelable(SAVESTATE_POLICY);
159 return mPolicy;
163 mPolicy = policy;
250 dest.writeParcelable(mPolicy, 0);
262 mPolicy = in.readParcelable(loader);
279 sb.append(mPolicy == null ? "none" : "exists");
/packages/apps/Settings/src/com/android/settings/fuelgauge/anomaly/
H A DAnomalyLoader.java50 AnomalyDetectionPolicy mPolicy; field in class:AnomalyLoader
82 mPolicy = policy;
101 return mAnomalyUtils.detectAnomalies(mBatteryStatsHelper, mPolicy, mPackageName);
/packages/apps/Settings/src/com/android/settings/datausage/
H A DChartDataUsagePreference.java44 private NetworkPolicy mPolicy; field in class:ChartDataUsagePreference
74 bindNetworkPolicy(chart, mPolicy, top);
89 long policyMax = mPolicy != null ? Math.max(mPolicy.limitBytes, mPolicy.warningBytes) : 0;
166 mPolicy = policy;

Completed in 348 milliseconds

123