0
プラットフォーム2.1の同じsharedUserIdを使用して、1つのアクティビティを強制終了できますか? ちょうど1つ。同じsharedUserIdを持つアクティビティの1つを強制終了できますか?
プラットフォーム2.1の同じsharedUserIdを使用して、1つのアクティビティを強制終了できますか? ちょうど1つ。同じsharedUserIdを持つアクティビティの1つを強制終了できますか?
finish()
を呼び出すActivity
オブジェクトがないため、直接ではありません。
ActivityManagerService.java:
long callingId = Binder.clearCallingIdentity();
ArrayList history = mHistory;
try {
synchronized (this) {
for (int i = history.size() - 1; i >= 0; --i) {
HistoryRecord r = (HistoryRecord) history.get(i);
if (r.packageName.equals(packageName)) {
if (Config.LOGD)
Log.d(TAG, " Force finishing activity "
+ r.intent.getComponent().flattenToShortString());
if (null != r.app) {
r.app.removed = true;
}
r.app = null;
finishActivityLocked(r, i, Activity.RESULT_CANCELED, null, "uninstall");
}
}
}
} finally {
Binder.restoreCallingIdentity(callingId);
}