Skip to content

Commit a3af313

Browse files
committed
force onBind from abstract class
1 parent e5b9c00 commit a3af313

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

pythonforandroid/bootstraps/service_only/build/src/org/kivy/android/PythonService.java

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
11
package org.kivy.android;
22

3-
import android.app.Activity;
43
import android.app.PendingIntent;
54
import android.app.Service;
65
import android.content.Context;
76
import android.content.Intent;
87
import android.content.pm.ApplicationInfo;
98
import android.os.Bundle;
10-
import android.os.IBinder;
119
import android.os.Process;
1210
import android.support.v4.app.NotificationCompat;
1311
import android.util.Log;
1412

15-
public class PythonService extends Service implements Runnable {
13+
public abstract class PythonService extends Service implements Runnable {
1614
private static String TAG = PythonService.class.getSimpleName();
1715

1816
/**
@@ -43,14 +41,6 @@ public boolean getAutoRestart() {
4341
return false;
4442
}
4543

46-
/**
47-
* {@inheritDoc}
48-
*/
49-
@Override
50-
public IBinder onBind(Intent intent) {
51-
return null;
52-
}
53-
5444
/**
5545
* {@inheritDoc}
5646
*/
@@ -109,7 +99,7 @@ protected void doStartForeground(Bundle extras) {
10999

110100
int NOTIFICATION_ID = 1;
111101

112-
Intent targetIntent = new Intent(this, Activity.class);
102+
Intent targetIntent = new Intent(this, MainActivity.class);
113103
PendingIntent contentIntent = PendingIntent.getActivity(this, 0, targetIntent, PendingIntent.FLAG_UPDATE_CURRENT);
114104
builder.setContentIntent(contentIntent);
115105

0 commit comments

Comments
 (0)