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

Commit d65817b1 authored by Steve Kondik's avatar Steve Kondik Committed by Gerrit Code Review
Browse files

Merge "Frameworks/SystemUI: Hide expanded dialog when screen is off" into ics

parents 5482c3cf 472ea3e0
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -437,6 +437,7 @@ public class PhoneStatusBar extends StatusBar {
        IntentFilter filter = new IntentFilter();
        filter.addAction(Intent.ACTION_CONFIGURATION_CHANGED);
        filter.addAction(Intent.ACTION_CLOSE_SYSTEM_DIALOGS);
        filter.addAction(Intent.ACTION_SCREEN_ON);
        filter.addAction(Intent.ACTION_SCREEN_OFF);
        context.registerReceiver(mBroadcastReceiver, filter);

@@ -2314,10 +2315,20 @@ public class PhoneStatusBar extends StatusBar {
                    }
                }
                animateCollapse(excludeRecents);
                if(Intent.ACTION_SCREEN_OFF.equals(action)) {
                    // Explicitly hide the expanded dialog. Otherwise it
                    // causes continuous buffer updates to SurfaceTexture
                    // even when SCREEN is turned off (while In-Call).
                    // This keeps the power consumption to a minimum
                    // in such a scenario.
                    mExpandedDialog.hide();
                }
            }
            else if (Intent.ACTION_CONFIGURATION_CHANGED.equals(action)) {
                repositionNavigationBar();
                updateResources();
            } else if (Intent.ACTION_SCREEN_ON.equals(action)) {
                mExpandedDialog.show();
            }
        }
    };