Loading packages/SystemUI/Android.bp +7 −0 Original line number Diff line number Diff line Loading @@ -33,6 +33,13 @@ java_library { srcs: ["src/com/android/systemui/EventLogTags.logtags"], } java_library { name: "SystemUI-sensors", srcs: [ "src/com/android/systemui/util/sensors/ThresholdSensor.java", ] } android_library { name: "SystemUI-core", srcs: [ Loading packages/SystemUI/plugin/Android.bp +2 −1 Original line number Diff line number Diff line Loading @@ -19,7 +19,8 @@ java_library { srcs: ["src/**/*.java"], static_libs: [ "PluginCoreLib" "PluginCoreLib", "SystemUI-sensors", ], } Loading packages/SystemUI/plugin/src/com/android/systemui/plugins/FalsingManager.java +4 −54 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.net.Uri; import android.view.MotionEvent; import com.android.systemui.plugins.annotations.ProvidesInterface; import com.android.systemui.util.sensors.ThresholdSensor; import java.io.FileDescriptor; import java.io.PrintWriter; Loading @@ -35,12 +36,6 @@ public interface FalsingManager { void onSuccessfulUnlock(); void onNotificationActive(); void setShowingAod(boolean showingAod); void onNotificatonStartDraggingDown(); boolean isUnlockingDisabled(); /** Returns true if the gesture should be rejected. */ Loading Loading @@ -82,66 +77,21 @@ public interface FalsingManager { */ boolean isFalseDoubleTap(); void onNotificatonStopDraggingDown(); void setNotificationExpanded(); boolean isClassifierEnabled(); void onQsDown(); void setQsExpanded(boolean expanded); boolean shouldEnforceBouncer(); void onTrackingStarted(boolean secure); void onTrackingStopped(); void onLeftAffordanceOn(); void onCameraOn(); void onAffordanceSwipingStarted(boolean rightCorner); void onAffordanceSwipingAborted(); void onStartExpandingFromPulse(); void onExpansionFromPulseStopped(); Uri reportRejectedTouch(); void onScreenOnFromTouch(); boolean isReportingEnabled(); void onUnlockHintStarted(); void onCameraHintStarted(); void onLeftAffordanceHintStarted(); void onScreenTurningOn(); void onScreenOff(); void onNotificationStopDismissing(); void onNotificationDismissed(); void onNotificationStartDismissing(); void onNotificationDoubleTap(boolean accepted, float dx, float dy); void onBouncerShown(); void onBouncerHidden(); void onTouchEvent(MotionEvent ev, int width, int height); /** From com.android.systemui.Dumpable. */ void dump(FileDescriptor fd, PrintWriter pw, String[] args); void cleanup(); /** Call to report a ProximityEvent to the FalsingManager. */ void onProximityEvent(ThresholdSensor.ThresholdSensorEvent proximityEvent); } packages/SystemUI/src/com/android/systemui/classifier/FalsingCollector.java 0 → 100644 +121 −0 Original line number Diff line number Diff line /* * Copyright (C) 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.systemui.classifier; import android.view.MotionEvent; /** * Defines a class that can be used to ingest system events for later processing. */ public interface FalsingCollector { /** */ void onSuccessfulUnlock(); /** */ void onNotificationActive(); /** */ void setShowingAod(boolean showingAod); /** */ void onNotificationStartDraggingDown(); /** */ void onNotificationStopDraggingDown(); /** */ void setNotificationExpanded(); /** */ void onQsDown(); /** */ void setQsExpanded(boolean expanded); /** */ boolean shouldEnforceBouncer(); /** */ void onTrackingStarted(boolean secure); /** */ void onTrackingStopped(); /** */ void onLeftAffordanceOn(); /** */ void onCameraOn(); /** */ void onAffordanceSwipingStarted(boolean rightCorner); /** */ void onAffordanceSwipingAborted(); /** */ void onStartExpandingFromPulse(); /** */ void onExpansionFromPulseStopped(); /** */ void onScreenOnFromTouch(); /** */ boolean isReportingEnabled(); /** */ void onUnlockHintStarted(); /** */ void onCameraHintStarted(); /** */ void onLeftAffordanceHintStarted(); /** */ void onScreenTurningOn(); /** */ void onScreenOff(); /** */ void onNotificationStopDismissing(); /** */ void onNotificationDismissed(); /** */ void onNotificationStartDismissing(); /** */ void onNotificationDoubleTap(boolean accepted, float dx, float dy); /** */ void onBouncerShown(); /** */ void onBouncerHidden(); /** */ void onTouchEvent(MotionEvent ev, int width, int height); /** */ void cleanup(); } packages/SystemUI/src/com/android/systemui/classifier/FalsingCollectorFake.java 0 → 100644 +152 −0 Original line number Diff line number Diff line /* * Copyright (C) 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.systemui.classifier; import android.view.MotionEvent; /** */ public class FalsingCollectorFake implements FalsingCollector { @Override public void onSuccessfulUnlock() { } @Override public void onNotificationActive() { } @Override public void setShowingAod(boolean showingAod) { } @Override public void onNotificationStartDraggingDown() { } @Override public void onNotificationStopDraggingDown() { } @Override public void setNotificationExpanded() { } @Override public void onQsDown() { } @Override public void setQsExpanded(boolean expanded) { } @Override public boolean shouldEnforceBouncer() { return false; } @Override public void onTrackingStarted(boolean secure) { } @Override public void onTrackingStopped() { } @Override public void onLeftAffordanceOn() { } @Override public void onCameraOn() { } @Override public void onAffordanceSwipingStarted(boolean rightCorner) { } @Override public void onAffordanceSwipingAborted() { } @Override public void onStartExpandingFromPulse() { } @Override public void onExpansionFromPulseStopped() { } @Override public void onScreenOnFromTouch() { } @Override public boolean isReportingEnabled() { return false; } @Override public void onUnlockHintStarted() { } @Override public void onCameraHintStarted() { } @Override public void onLeftAffordanceHintStarted() { } @Override public void onScreenTurningOn() { } @Override public void onScreenOff() { } @Override public void onNotificationStopDismissing() { } @Override public void onNotificationDismissed() { } @Override public void onNotificationStartDismissing() { } @Override public void onNotificationDoubleTap(boolean accepted, float dx, float dy) { } @Override public void onBouncerShown() { } @Override public void onBouncerHidden() { } @Override public void onTouchEvent(MotionEvent ev, int width, int height) { } @Override public void cleanup() { } } Loading
packages/SystemUI/Android.bp +7 −0 Original line number Diff line number Diff line Loading @@ -33,6 +33,13 @@ java_library { srcs: ["src/com/android/systemui/EventLogTags.logtags"], } java_library { name: "SystemUI-sensors", srcs: [ "src/com/android/systemui/util/sensors/ThresholdSensor.java", ] } android_library { name: "SystemUI-core", srcs: [ Loading
packages/SystemUI/plugin/Android.bp +2 −1 Original line number Diff line number Diff line Loading @@ -19,7 +19,8 @@ java_library { srcs: ["src/**/*.java"], static_libs: [ "PluginCoreLib" "PluginCoreLib", "SystemUI-sensors", ], } Loading
packages/SystemUI/plugin/src/com/android/systemui/plugins/FalsingManager.java +4 −54 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.net.Uri; import android.view.MotionEvent; import com.android.systemui.plugins.annotations.ProvidesInterface; import com.android.systemui.util.sensors.ThresholdSensor; import java.io.FileDescriptor; import java.io.PrintWriter; Loading @@ -35,12 +36,6 @@ public interface FalsingManager { void onSuccessfulUnlock(); void onNotificationActive(); void setShowingAod(boolean showingAod); void onNotificatonStartDraggingDown(); boolean isUnlockingDisabled(); /** Returns true if the gesture should be rejected. */ Loading Loading @@ -82,66 +77,21 @@ public interface FalsingManager { */ boolean isFalseDoubleTap(); void onNotificatonStopDraggingDown(); void setNotificationExpanded(); boolean isClassifierEnabled(); void onQsDown(); void setQsExpanded(boolean expanded); boolean shouldEnforceBouncer(); void onTrackingStarted(boolean secure); void onTrackingStopped(); void onLeftAffordanceOn(); void onCameraOn(); void onAffordanceSwipingStarted(boolean rightCorner); void onAffordanceSwipingAborted(); void onStartExpandingFromPulse(); void onExpansionFromPulseStopped(); Uri reportRejectedTouch(); void onScreenOnFromTouch(); boolean isReportingEnabled(); void onUnlockHintStarted(); void onCameraHintStarted(); void onLeftAffordanceHintStarted(); void onScreenTurningOn(); void onScreenOff(); void onNotificationStopDismissing(); void onNotificationDismissed(); void onNotificationStartDismissing(); void onNotificationDoubleTap(boolean accepted, float dx, float dy); void onBouncerShown(); void onBouncerHidden(); void onTouchEvent(MotionEvent ev, int width, int height); /** From com.android.systemui.Dumpable. */ void dump(FileDescriptor fd, PrintWriter pw, String[] args); void cleanup(); /** Call to report a ProximityEvent to the FalsingManager. */ void onProximityEvent(ThresholdSensor.ThresholdSensorEvent proximityEvent); }
packages/SystemUI/src/com/android/systemui/classifier/FalsingCollector.java 0 → 100644 +121 −0 Original line number Diff line number Diff line /* * Copyright (C) 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.systemui.classifier; import android.view.MotionEvent; /** * Defines a class that can be used to ingest system events for later processing. */ public interface FalsingCollector { /** */ void onSuccessfulUnlock(); /** */ void onNotificationActive(); /** */ void setShowingAod(boolean showingAod); /** */ void onNotificationStartDraggingDown(); /** */ void onNotificationStopDraggingDown(); /** */ void setNotificationExpanded(); /** */ void onQsDown(); /** */ void setQsExpanded(boolean expanded); /** */ boolean shouldEnforceBouncer(); /** */ void onTrackingStarted(boolean secure); /** */ void onTrackingStopped(); /** */ void onLeftAffordanceOn(); /** */ void onCameraOn(); /** */ void onAffordanceSwipingStarted(boolean rightCorner); /** */ void onAffordanceSwipingAborted(); /** */ void onStartExpandingFromPulse(); /** */ void onExpansionFromPulseStopped(); /** */ void onScreenOnFromTouch(); /** */ boolean isReportingEnabled(); /** */ void onUnlockHintStarted(); /** */ void onCameraHintStarted(); /** */ void onLeftAffordanceHintStarted(); /** */ void onScreenTurningOn(); /** */ void onScreenOff(); /** */ void onNotificationStopDismissing(); /** */ void onNotificationDismissed(); /** */ void onNotificationStartDismissing(); /** */ void onNotificationDoubleTap(boolean accepted, float dx, float dy); /** */ void onBouncerShown(); /** */ void onBouncerHidden(); /** */ void onTouchEvent(MotionEvent ev, int width, int height); /** */ void cleanup(); }
packages/SystemUI/src/com/android/systemui/classifier/FalsingCollectorFake.java 0 → 100644 +152 −0 Original line number Diff line number Diff line /* * Copyright (C) 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.systemui.classifier; import android.view.MotionEvent; /** */ public class FalsingCollectorFake implements FalsingCollector { @Override public void onSuccessfulUnlock() { } @Override public void onNotificationActive() { } @Override public void setShowingAod(boolean showingAod) { } @Override public void onNotificationStartDraggingDown() { } @Override public void onNotificationStopDraggingDown() { } @Override public void setNotificationExpanded() { } @Override public void onQsDown() { } @Override public void setQsExpanded(boolean expanded) { } @Override public boolean shouldEnforceBouncer() { return false; } @Override public void onTrackingStarted(boolean secure) { } @Override public void onTrackingStopped() { } @Override public void onLeftAffordanceOn() { } @Override public void onCameraOn() { } @Override public void onAffordanceSwipingStarted(boolean rightCorner) { } @Override public void onAffordanceSwipingAborted() { } @Override public void onStartExpandingFromPulse() { } @Override public void onExpansionFromPulseStopped() { } @Override public void onScreenOnFromTouch() { } @Override public boolean isReportingEnabled() { return false; } @Override public void onUnlockHintStarted() { } @Override public void onCameraHintStarted() { } @Override public void onLeftAffordanceHintStarted() { } @Override public void onScreenTurningOn() { } @Override public void onScreenOff() { } @Override public void onNotificationStopDismissing() { } @Override public void onNotificationDismissed() { } @Override public void onNotificationStartDismissing() { } @Override public void onNotificationDoubleTap(boolean accepted, float dx, float dy) { } @Override public void onBouncerShown() { } @Override public void onBouncerHidden() { } @Override public void onTouchEvent(MotionEvent ev, int width, int height) { } @Override public void cleanup() { } }