Merge "Perform activityIdleInternal in correct order."