Added service

This commit is contained in:
Swapnil Tripathi 2021-07-28 15:39:07 +05:30 committed by Tobias Fella
parent 9968f086ab
commit 3148c776f3
4 changed files with 35 additions and 1 deletions

View File

@ -7,7 +7,7 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.kde.kasts"
android:versionName="0.0.1"
android:versionCode="1588098483"
android:versionCode="1627466509"
android:installLocation="auto">
<supports-screens android:largeScreens="true" android:normalScreens="true" android:anyDensity="true" android:smallScreens="true"/>
@ -57,6 +57,9 @@
<!-- auto screen scale factor -->
<meta-data android:name="android.app.auto_screen_scale_factor" android:value="true"/>
</activity>
<service android:name="org.kde.kasts.MediaService" >
<meta-data android:name="android.app.background_running" android:value="true"/>
</service>
</application>
</manifest>

View File

@ -28,6 +28,7 @@ def timestamp = (int)(new Date().getTime()/1000)
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar', '*.aar'])
implementation 'com.android.support:support-v4:28.0.0'
}
android {

View File

@ -0,0 +1 @@
android.useAndroidX=true

View File

@ -0,0 +1,29 @@
/**
* SPDX-FileCopyrightText: 2021 Swapnil Tripathi <swapnil06.st@gmail.com>
*
* SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
*/
package org.kde.kasts;
import android.app.Service;
import android.content.Intent;
import android.os.IBinder;
import android.os.Bundle;
import android.support.v4.media.session.MediaSessionCompat;
public class MediaService extends Service {
public static final String TAG = "MediaService";
private MediaSessionCompat mSession;
@Override
public IBinder onBind(Intent intent) {
return null;
}
@Override
public void onCreate() {
super.onCreate();
}
}