Changeset View
Changeset View
Standalone View
Standalone View
data/src/org/kde/elisa/ElisaService.java
1 | package org.kde.elisa; | 1 | package org.kde.elisa; | ||
---|---|---|---|---|---|
2 | 2 | | |||
3 | import android.content.Context; | 3 | import android.content.Context; | ||
4 | import android.database.Cursor; | ||||
4 | import android.content.Intent; | 5 | import android.content.Intent; | ||
6 | import android.provider.MediaStore; | ||||
5 | 7 | | |||
6 | import org.qtproject.qt5.android.bindings.QtService; | 8 | import org.qtproject.qt5.android.bindings.QtService; | ||
7 | 9 | | |||
10 | class ElisaNatives { | ||||
11 | | ||||
12 | // declare the native method | ||||
13 | public static native void sendMusicFile(String musicFile); | ||||
14 | } | ||||
15 | | ||||
8 | /** | 16 | /** | ||
9 | * Created by mgallien on 02/05/17. | 17 | * Created by mgallien on 02/05/17. | ||
10 | */ | 18 | */ | ||
11 | 19 | | |||
12 | public class ElisaService extends QtService { | 20 | public class ElisaService extends QtService { | ||
13 | public static void startMyService(Context ctx) { | 21 | public static void startMyService(Context ctx) { | ||
22 | //System.err.println("hello service"); | ||||
14 | ctx.startService(new Intent(ctx, ElisaService.class)); | 23 | ctx.startService(new Intent(ctx, ElisaService.class)); | ||
15 | } | 24 | } | ||
16 | } | 25 | } |