From 4a6b0ea5ade7d16b6b73f28f0c9556424bdecd6a Mon Sep 17 00:00:00 2001 From: Matthew Fritze Date: Mon, 21 Sep 2020 13:24:29 -0700 Subject: [PATCH] Add initial emergency (gesture) intent action The intent will be triggered by a new emergency gesture for helping users in unsafe situations. Bug: 169082308 Test: None. Change-Id: Ib3309db6b4991a2962c66924c29bedec4cb577a3 --- .../systemui/emergency/EmergencyGesture.java | 40 +++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 packages/SystemUI/src/com/android/systemui/emergency/EmergencyGesture.java diff --git a/packages/SystemUI/src/com/android/systemui/emergency/EmergencyGesture.java b/packages/SystemUI/src/com/android/systemui/emergency/EmergencyGesture.java new file mode 100644 index 0000000000000..dccb24dfe21e5 --- /dev/null +++ b/packages/SystemUI/src/com/android/systemui/emergency/EmergencyGesture.java @@ -0,0 +1,40 @@ +/* + * 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.emergency; + +/** + * Constants for the Emergency gesture. + * + * TODO (b/169175022) Update classname and docs when feature name is locked + */ +public final class EmergencyGesture { + + /** + * Launches the emergency flow. + * + *

The emergency flow is triggered by the Emergency gesture. By default the flow will call + * local emergency services, though OEMs can customize the flow. + * + *

This action can only be triggered by System UI through the emergency gesture. + * + *

TODO (b/169175022) Update action name and docs when feature name is locked + */ + public static final String ACTION_LAUNCH_EMERGENCY = + "com.android.systemui.action.LAUNCH_EMERGENCY"; + + private EmergencyGesture() {} +}