Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 70f1279e authored by Daniel Sandler's avatar Daniel Sandler Committed by Android Git Automerger
Browse files

am 63188574: Merge "Dismiss system windows when screen savers start." into ics-mr1

* commit '63188574':
  Dismiss system windows when screen savers start.
parents d7b06977 63188574
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -30,12 +30,17 @@ public class DreamsDockLauncher extends Activity {
                    com.android.internal.R.string.config_defaultDreamComponent);
            }
            if (component != null) {
                // dismiss the notification shade, recents, etc.
                context.sendBroadcast(new Intent(Intent.ACTION_CLOSE_SYSTEM_DIALOGS));

                ComponentName cn = ComponentName.unflattenFromString(component);
                Intent zzz = new Intent(Intent.ACTION_MAIN)
                    .setComponent(cn)
                    .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK
                            | Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS
                            | Intent.FLAG_ACTIVITY_NO_USER_ACTION
                            | Intent.FLAG_FROM_BACKGROUND
                            | Intent.FLAG_ACTIVITY_NO_HISTORY
                        );
                Slog.v(TAG, "Starting screen saver on dock event: " + component);
                context.startActivity(zzz);
+5 −0
Original line number Diff line number Diff line
@@ -3475,12 +3475,17 @@ public class PhoneWindowManager implements WindowManagerPolicy {
                    component = mContext.getResources().getString(R.string.config_defaultDreamComponent);
                }
                if (component != null) {
                    // dismiss the notification shade, recents, etc.
                    mContext.sendBroadcast(new Intent(Intent.ACTION_CLOSE_SYSTEM_DIALOGS));

                    ComponentName cn = ComponentName.unflattenFromString(component);
                    Intent intent = new Intent(Intent.ACTION_MAIN)
                        .setComponent(cn)
                        .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK
                            | Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS
                            | Intent.FLAG_ACTIVITY_NO_USER_ACTION
                            | Intent.FLAG_FROM_BACKGROUND
                            | Intent.FLAG_ACTIVITY_NO_HISTORY
                            );
                    mContext.startActivity(intent);
                } else {