pull/330/head
AriaLyy 8 years ago
parent 2b21d98e77
commit 0715ffeb9b
  1. 15
      Aria/src/main/java/com/arialyy/aria/core/AriaManager.java

@ -49,12 +49,12 @@ import java.util.Set;
* Aria管理器任务操作在这里执行 * Aria管理器任务操作在这里执行
*/ */
@TargetApi(Build.VERSION_CODES.ICE_CREAM_SANDWICH) public class AriaManager { @TargetApi(Build.VERSION_CODES.ICE_CREAM_SANDWICH) public class AriaManager {
private static final String TAG = "AriaManager"; private static final String TAG = "AriaManager";
private static final Object LOCK = new Object(); private static final Object LOCK = new Object();
private static volatile AriaManager INSTANCE = null; private static volatile AriaManager INSTANCE = null;
private Map<String, AMReceiver> mTargets = new HashMap<>(); private Map<String, AMReceiver> mTargets = new HashMap<>();
private DownloadManager mManager; private DownloadManager mManager;
private LifeCallback mLifeCallback; private LifeCallback mLifeCallback;
private AriaManager(Context context) { private AriaManager(Context context) {
regAppLifeCallback(context); regAppLifeCallback(context);
@ -218,7 +218,10 @@ import java.util.Set;
} }
handlePopupWindowLift((PopupWindow) obj); handlePopupWindowLift((PopupWindow) obj);
} }
} else { }
if (obj instanceof Activity || obj instanceof Service) {
key = clsName;
} else if (obj instanceof Application) {
key = clsName; key = clsName;
} }
if (TextUtils.isEmpty(key)) { if (TextUtils.isEmpty(key)) {

Loading…
Cancel
Save