Loading core/java/android/backup/BackupManager.java +10 −6 Original line number Diff line number Diff line Loading @@ -68,11 +68,13 @@ public class BackupManager { * {@link android.app.BackupAgent} subclass will be scheduled when you call this method. */ public void dataChanged() { if (mService != null) { try { mService.dataChanged(mContext.getPackageName()); } catch (RemoteException e) { } } } /** * Begin the process of restoring system data from backup. This method requires Loading @@ -83,10 +85,12 @@ public class BackupManager { */ public IRestoreSession beginRestoreSession(int transportID) { IRestoreSession binder = null; if (mService != null) { try { binder = mService.beginRestoreSession(transportID); } catch (RemoteException e) { } } return binder; } } services/java/com/android/server/am/ActivityManagerService.java +9 −0 Original line number Diff line number Diff line Loading @@ -10514,8 +10514,17 @@ public final class ActivityManagerService extends ActivityManagerNative implemen // done with this agent public void unbindBackupAgent(ApplicationInfo appInfo) { if (DEBUG_BACKUP) Log.v(TAG, "unbindBackupAgent: " + appInfo); if (appInfo == null) { Log.w(TAG, "unbind backup agent for null app"); return; } synchronized(this) { if (mBackupAppName == null) { Log.w(TAG, "Unbinding backup agent with no active backup"); return; } if (!mBackupAppName.equals(appInfo.packageName)) { Log.e(TAG, "Unbind of " + appInfo + " but is not the current backup target"); return; Loading Loading
core/java/android/backup/BackupManager.java +10 −6 Original line number Diff line number Diff line Loading @@ -68,11 +68,13 @@ public class BackupManager { * {@link android.app.BackupAgent} subclass will be scheduled when you call this method. */ public void dataChanged() { if (mService != null) { try { mService.dataChanged(mContext.getPackageName()); } catch (RemoteException e) { } } } /** * Begin the process of restoring system data from backup. This method requires Loading @@ -83,10 +85,12 @@ public class BackupManager { */ public IRestoreSession beginRestoreSession(int transportID) { IRestoreSession binder = null; if (mService != null) { try { binder = mService.beginRestoreSession(transportID); } catch (RemoteException e) { } } return binder; } }
services/java/com/android/server/am/ActivityManagerService.java +9 −0 Original line number Diff line number Diff line Loading @@ -10514,8 +10514,17 @@ public final class ActivityManagerService extends ActivityManagerNative implemen // done with this agent public void unbindBackupAgent(ApplicationInfo appInfo) { if (DEBUG_BACKUP) Log.v(TAG, "unbindBackupAgent: " + appInfo); if (appInfo == null) { Log.w(TAG, "unbind backup agent for null app"); return; } synchronized(this) { if (mBackupAppName == null) { Log.w(TAG, "Unbinding backup agent with no active backup"); return; } if (!mBackupAppName.equals(appInfo.packageName)) { Log.e(TAG, "Unbind of " + appInfo + " but is not the current backup target"); return; Loading