Loading quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java +7 −0 Original line number Diff line number Diff line Loading @@ -101,6 +101,7 @@ import android.text.TextUtils; import android.util.AttributeSet; import android.view.HapticFeedbackConstants; import android.view.KeyEvent; import android.view.MotionEvent; import android.view.View; import android.widget.AnalogClock; import android.widget.TextClock; Loading Loading @@ -1318,6 +1319,12 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, .playPlaceholderDismissAnim(this, splitDismissEvent); } @Override public void onSleepEvent(MotionEvent ev) { super.onSleepEvent(ev); SystemUiProxy.INSTANCE.get(this).onSleepEvent(ev); } @Override public OverviewActionsView<?> getActionsView() { return mActionsView; Loading quickstep/src/com/android/quickstep/SystemUiProxy.kt +8 −0 Original line number Diff line number Diff line Loading @@ -419,6 +419,14 @@ class SystemUiProxy @Inject constructor( } } @MainThread fun onSleepEvent(event: MotionEvent) { Preconditions.assertUIThread() executeWithErrorLog({ "Failed call onSleepEvent with arg: $event" }) { systemUiProxy?.onSleepEvent(event) } } fun onStatusBarTrackpadEvent(event: MotionEvent) = executeWithErrorLog({ "Failed call onStatusBarTrackpadEvent with arg: $event" }) { systemUiProxy?.onStatusBarTrackpadEvent(event) Loading res/values/lineage_strings.xml +4 −0 Original line number Diff line number Diff line Loading @@ -47,6 +47,10 @@ <string name="drawer_open_keyboard_title">Swipe to start search</string> <string name="drawer_open_keyboard_summary">Open keyboard whenever app drawer becomes visible</string> <!-- Sleep gesture --> <string name="pref_sleep_gesture_title">Double tap to sleep</string> <string name="pref_sleep_gesture_summary">Double tap empty space on home screen to turn off the screen</string> <!-- Trust apps --> <string name="trust_apps_manager_name">Hidden & Protected apps</string> <string name="trust_apps_auth_manager">Unlock to manage the hidden and protected apps</string> Loading res/xml/launcher_preferences.xml +7 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,13 @@ android:summaryOn="@string/settings_lock_layout_summary_on" android:summaryOff="@string/settings_lock_layout_summary_off" /> <SwitchPreferenceCompat android:defaultValue="false" android:key="pref_sleep_gesture" android:persistent="true" android:title="@string/pref_sleep_gesture_title" android:summary="@string/pref_sleep_gesture_summary" /> <com.android.launcher3.settings.NotificationDotsPreference android:key="pref_icon_badging" android:title="@string/notification_dots_title" Loading src/com/android/launcher3/Launcher.java +5 −0 Original line number Diff line number Diff line Loading @@ -2673,6 +2673,11 @@ public class Launcher extends StatefulActivity<LauncherState> // Overridden } /** To be overrideden by subclasses */ public void onSleepEvent(MotionEvent ev) { // Overridden } public void closeOpenViews() { closeOpenViews(true); } Loading Loading
quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java +7 −0 Original line number Diff line number Diff line Loading @@ -101,6 +101,7 @@ import android.text.TextUtils; import android.util.AttributeSet; import android.view.HapticFeedbackConstants; import android.view.KeyEvent; import android.view.MotionEvent; import android.view.View; import android.widget.AnalogClock; import android.widget.TextClock; Loading Loading @@ -1318,6 +1319,12 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, .playPlaceholderDismissAnim(this, splitDismissEvent); } @Override public void onSleepEvent(MotionEvent ev) { super.onSleepEvent(ev); SystemUiProxy.INSTANCE.get(this).onSleepEvent(ev); } @Override public OverviewActionsView<?> getActionsView() { return mActionsView; Loading
quickstep/src/com/android/quickstep/SystemUiProxy.kt +8 −0 Original line number Diff line number Diff line Loading @@ -419,6 +419,14 @@ class SystemUiProxy @Inject constructor( } } @MainThread fun onSleepEvent(event: MotionEvent) { Preconditions.assertUIThread() executeWithErrorLog({ "Failed call onSleepEvent with arg: $event" }) { systemUiProxy?.onSleepEvent(event) } } fun onStatusBarTrackpadEvent(event: MotionEvent) = executeWithErrorLog({ "Failed call onStatusBarTrackpadEvent with arg: $event" }) { systemUiProxy?.onStatusBarTrackpadEvent(event) Loading
res/values/lineage_strings.xml +4 −0 Original line number Diff line number Diff line Loading @@ -47,6 +47,10 @@ <string name="drawer_open_keyboard_title">Swipe to start search</string> <string name="drawer_open_keyboard_summary">Open keyboard whenever app drawer becomes visible</string> <!-- Sleep gesture --> <string name="pref_sleep_gesture_title">Double tap to sleep</string> <string name="pref_sleep_gesture_summary">Double tap empty space on home screen to turn off the screen</string> <!-- Trust apps --> <string name="trust_apps_manager_name">Hidden & Protected apps</string> <string name="trust_apps_auth_manager">Unlock to manage the hidden and protected apps</string> Loading
res/xml/launcher_preferences.xml +7 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,13 @@ android:summaryOn="@string/settings_lock_layout_summary_on" android:summaryOff="@string/settings_lock_layout_summary_off" /> <SwitchPreferenceCompat android:defaultValue="false" android:key="pref_sleep_gesture" android:persistent="true" android:title="@string/pref_sleep_gesture_title" android:summary="@string/pref_sleep_gesture_summary" /> <com.android.launcher3.settings.NotificationDotsPreference android:key="pref_icon_badging" android:title="@string/notification_dots_title" Loading
src/com/android/launcher3/Launcher.java +5 −0 Original line number Diff line number Diff line Loading @@ -2673,6 +2673,11 @@ public class Launcher extends StatefulActivity<LauncherState> // Overridden } /** To be overrideden by subclasses */ public void onSleepEvent(MotionEvent ev) { // Overridden } public void closeOpenViews() { closeOpenViews(true); } Loading