This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public void onDestroy() { | |
| super.onDestroy(); | |
| boolean anyParentIsRemoving = false; | |
| for (Fragment parent = this.getParentFragment(); !anyParentIsRemoving && parent != null; | |
| parent = parent.getParentFragment()) { | |
| anyParentIsRemoving = parent.isRemoving(); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.arellomobile.wagamamamvp; | |
| import android.app.Service; | |
| import android.content.Intent; | |
| import android.graphics.PixelFormat; | |
| import android.os.Handler; | |
| import android.os.IBinder; | |
| import android.support.annotation.Nullable; | |
| import android.util.Log; | |
| import android.view.LayoutInflater; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <activity android:name=".MainActivity" | |
| android:showOnLockScreen="true"> | |
| <intent-filter> | |
| <action android:name="android.intent.action.MAIN" /> | |
| <category android:name="android.intent.category.LAUNCHER" /> | |
| </intent-filter> | |
| </activity> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private static PendingIntent getAlarmIntent(Context context) | |
| { | |
| return PendingIntent.getService(context, 0, new AlarmIntent(context, GeoLocationService.class).putExtra(KEY_INTENT_FLAG, VALUE_START), PendingIntent.FLAG_UPDATE_CURRENT); | |
| } | |
| private static void cancelAlarm(Context context) | |
| { | |
| PendingIntent pendingIntent = getAlarmIntent(context); | |
| AlarmManager alarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); | |
| alarmManager.cancel(pendingIntent); |
NewerOlder