Add minimal Android launcher application
This commit is contained in:
parent
c0ec6e33d7
commit
cfbfa78004
5 changed files with 114 additions and 4 deletions
14
Android.mk
14
Android.mk
|
|
@ -1,4 +1,4 @@
|
|||
LOCAL_PATH:= $(call my-dir)
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := libprocess-cpp-minimal
|
||||
|
|
@ -52,6 +52,12 @@ LOCAL_CFLAGS := \
|
|||
-std=c++1y
|
||||
include $(BUILD_EXECUTABLE)
|
||||
|
||||
# The compositor has its Android.mk in its subfolder as it should not
|
||||
# depend on any other anbox sources.
|
||||
include $(call all-makefiles-under, $(LOCAL_PATH)/android/shared_compositor)
|
||||
# Include the Android.mk files below will override LOCAL_PATH so we
|
||||
# have to take a copy of it here.
|
||||
TMP_PATH := $(LOCAL_PATH)
|
||||
|
||||
# The compositor and launcher have their own Android.mk in their subfolders
|
||||
# as they should not depend on any other anbox sources.
|
||||
# include $(LOCAL_PATH)/android/shared_compositor/Android.mk
|
||||
include $(TMP_PATH)/android/launcher/Android.mk
|
||||
include $(TMP_PATH)/android/shared_compositor/Android.mk
|
||||
|
|
|
|||
11
android/launcher/Android.mk
Normal file
11
android/launcher/Android.mk
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
LOCAL_PATH := $(call my-dir)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_SRC_FILES := \
|
||||
$(call all-java-files-under src)
|
||||
LOCAL_SDK_VERSION := current
|
||||
LOCAL_PACKAGE_NAME := AnboxLauncher
|
||||
LOCAL_CERTIFICATE := shared
|
||||
LOCAL_PRIVILEGED_MODULE := true
|
||||
LOCAL_OVERRIDES_PACKAGES := Home
|
||||
include $(BUILD_PACKAGE)
|
||||
28
android/launcher/AndroidManifest.xml
Normal file
28
android/launcher/AndroidManifest.xml
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="org.anbox.launcher">
|
||||
|
||||
<application
|
||||
android:name="org.anbox.launcher.LauncherApplication"
|
||||
android:label="Anbox Launcher"
|
||||
android:hardwareAccelerated="true"
|
||||
android:largeHeap="false"
|
||||
android:supportsRtl="true">
|
||||
<activity
|
||||
android:name="org.anbox.launcher.Launcher"
|
||||
android:launchMode="singleTask"
|
||||
android:clearTaskOnLaunch="true"
|
||||
android:stateNotNeeded="true"
|
||||
android:resumeWhilePausing="true"
|
||||
android:windowSoftInputMode="adjustPan"
|
||||
android:screenOrientation="nosensor">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.HOME" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<category android:name="android.intent.category.MONKEY"/>
|
||||
</intent-filter>
|
||||
</activity>
|
||||
</application>
|
||||
</manifest>
|
||||
33
android/launcher/src/org/anbox/launcher/Launcher.java
Normal file
33
android/launcher/src/org/anbox/launcher/Launcher.java
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
/*
|
||||
* Copyright (C) 2016 Simon Fels <morphis@gravedo.de>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 3, as published
|
||||
* by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranties of
|
||||
* MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License along
|
||||
* with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
package org.anbox.launcher;
|
||||
|
||||
import android.app.Activity;
|
||||
|
||||
/**
|
||||
* Default launcher application.
|
||||
*/
|
||||
public final class Launcher extends Activity {
|
||||
static final String TAG = "Launcher";
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
LauncherApplication app = ((LauncherApplication)getApplication());
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
/*
|
||||
* Copyright (C) 2016 Simon Fels <morphis@gravedo.de>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 3, as published
|
||||
* by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranties of
|
||||
* MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License along
|
||||
* with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
package org.anbox.launcher;
|
||||
|
||||
import android.app.Application;
|
||||
import android.util.Log;
|
||||
|
||||
import org.anbox.launcher.R;
|
||||
|
||||
public class LauncherApplication extends Application {
|
||||
static final String TAG = "LauncherApplication";
|
||||
|
||||
@Override
|
||||
public void onCreate() {
|
||||
super.onCreate();
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue