summaryrefslogtreecommitdiffstats
path: root/tests/Assist/src/com/android/test/assist/AboveKeyguardActivity.java
diff options
context:
space:
mode:
authorSelim Cinek <cinek@google.com>2015-05-05 23:53:22 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-05-05 23:53:23 +0000
commite9194b98a2098a1d94957e4723eaaf7399ecf3be (patch)
tree93be36d5499bba5c1f21df4598a0ab7e92121b36 /tests/Assist/src/com/android/test/assist/AboveKeyguardActivity.java
parent6329bbceebc8c0d6de164cb693a828402542fd35 (diff)
parent704b9f82c345da2d63bc2785fb3733b486d3e119 (diff)
downloadframeworks_base-e9194b98a2098a1d94957e4723eaaf7399ecf3be.zip
frameworks_base-e9194b98a2098a1d94957e4723eaaf7399ecf3be.tar.gz
frameworks_base-e9194b98a2098a1d94957e4723eaaf7399ecf3be.tar.bz2
Merge "Extended test to support launching assist above lock screen" into mnc-dev
Diffstat (limited to 'tests/Assist/src/com/android/test/assist/AboveKeyguardActivity.java')
-rw-r--r--tests/Assist/src/com/android/test/assist/AboveKeyguardActivity.java37
1 files changed, 37 insertions, 0 deletions
diff --git a/tests/Assist/src/com/android/test/assist/AboveKeyguardActivity.java b/tests/Assist/src/com/android/test/assist/AboveKeyguardActivity.java
new file mode 100644
index 0000000..3e37345
--- /dev/null
+++ b/tests/Assist/src/com/android/test/assist/AboveKeyguardActivity.java
@@ -0,0 +1,37 @@
+/*
+ * Copyright (C) 2015 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.test.assist;
+
+import android.annotation.Nullable;
+import android.app.Activity;
+import android.os.Bundle;
+import android.view.WindowManager;
+
+import com.android.test.assist.R;
+
+/**
+ * An activity which can be shown above the keyguard.
+ */
+public class AboveKeyguardActivity extends Activity {
+
+ @Override
+ protected void onCreate(@Nullable Bundle savedInstanceState) {
+ super.onCreate(savedInstanceState);
+ getWindow().addFlags(WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED);
+ setContentView(R.layout.keyguard_preview);
+ }
+}