using compat builder for notifications

This commit is contained in:
Nathan Freitas 2016-10-12 16:58:56 -04:00
parent 330860216a
commit 9de4f54e6b
1 changed files with 3 additions and 2 deletions

View File

@ -28,6 +28,7 @@ import android.net.NetworkInfo;
import android.os.Build;
import android.os.IBinder;
import android.os.RemoteException;
import android.support.v4.app.NotificationCompat;
import android.support.v4.content.LocalBroadcastManager;
import android.text.TextUtils;
import android.util.Log;
@ -102,7 +103,7 @@ public class TorService extends Service implements TorServiceConstants, OrbotCon
private int mNetworkType = -1;
private NotificationManager mNotificationManager = null;
private Notification.Builder mNotifyBuilder;
private NotificationCompat.Builder mNotifyBuilder;
private Notification mNotification;
private boolean mNotificationShowing = false;
@ -203,7 +204,7 @@ public class TorService extends Service implements TorServiceConstants, OrbotCon
if (mNotifyBuilder == null)
{
mNotifyBuilder = new Notification.Builder(this)
mNotifyBuilder = new NotificationCompat.Builder(this)
.setContentTitle(getString(R.string.app_name))
.setSmallIcon(R.drawable.ic_stat_tor);