From fc50f7cef8f55d7589a30ea7e88c1b59f70b0b05 Mon Sep 17 00:00:00 2001 From: d34d Date: Thu, 21 Jan 2016 16:57:42 -0800 Subject: ExtViews: Add action and meta-data Services that extend KeyguardExternalViewProviderService should also include this newly defined action in an intent-filter within the tag in their AndroidManifest.xml. These services can also include meta-data that defines a configuration xml which will be used to define a settings activity that can be launched within a yet to be defined settings/configuration UI. Change-Id: I0a5ca09cf6f63413d067f89a9757137102dd09f6 TICKET: CYNGNOS-1687 --- .../keyguardviewprovider/AndroidManifest.xml | 7 ++++++ .../keyguardviewprovider/res/xml/mylockscreen.xml | 3 +++ .../samples/keyguardextview/Settings.java | 28 ++++++++++++++++++++++ 3 files changed, 38 insertions(+) create mode 100644 samples/externalviews/keyguardviewprovider/res/xml/mylockscreen.xml create mode 100644 samples/externalviews/keyguardviewprovider/src/org/cyanogenmod/samples/keyguardextview/Settings.java (limited to 'samples/externalviews') diff --git a/samples/externalviews/keyguardviewprovider/AndroidManifest.xml b/samples/externalviews/keyguardviewprovider/AndroidManifest.xml index 145cd92..293c6b8 100644 --- a/samples/externalviews/keyguardviewprovider/AndroidManifest.xml +++ b/samples/externalviews/keyguardviewprovider/AndroidManifest.xml @@ -27,6 +27,13 @@ + + + + + diff --git a/samples/externalviews/keyguardviewprovider/res/xml/mylockscreen.xml b/samples/externalviews/keyguardviewprovider/res/xml/mylockscreen.xml new file mode 100644 index 0000000..6c4fcef --- /dev/null +++ b/samples/externalviews/keyguardviewprovider/res/xml/mylockscreen.xml @@ -0,0 +1,3 @@ + + \ No newline at end of file diff --git a/samples/externalviews/keyguardviewprovider/src/org/cyanogenmod/samples/keyguardextview/Settings.java b/samples/externalviews/keyguardviewprovider/src/org/cyanogenmod/samples/keyguardextview/Settings.java new file mode 100644 index 0000000..5fb130e --- /dev/null +++ b/samples/externalviews/keyguardviewprovider/src/org/cyanogenmod/samples/keyguardextview/Settings.java @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2016 The CyanogenMod 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 org.cyanogenmod.samples.keyguardextview; + +import android.app.Activity; +import android.os.Bundle; + +public class Settings extends Activity { + @Override + public void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + setContentView(R.layout.main); + } +} \ No newline at end of file -- cgit v1.1