void (@NotNull UiActivity activity, @NotNull ModalityState effectiveModalityState) { if (!myToWatch.isEmpty() && !myToWatch.contains(activity)) return; myActivities.put(activity, new ActivityInfo(effectiveModalityState)); myQueuedToRemove.remove(activity); myContainer.onActivityAdded(activity); }