2491 Commits

Author SHA1 Message Date
Craig Mautner
6f955df8e6 am 550b44d1: am f4644189: am 4cf6286c: am 02c7ba73: am 41bb0637: am 76e85eec: am 3bc9971d: am 95d6e32b: am 86f9a93e: Merge "Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs" into jb-mr1-dev
* commit '550b44d1884c5f65187dbc8bf8d4e6090f302a7b':
  Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs
2014-03-25 17:48:38 +00:00
Craig Mautner
4cf6286c3c am 02c7ba73: am 41bb0637: am 76e85eec: am 3bc9971d: am 95d6e32b: am 86f9a93e: Merge "Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs" into jb-mr1-dev
* commit '02c7ba73e8733def289535b6d13dc6a504a0443f':
  Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs
2014-03-25 10:29:48 -07:00
Craig Mautner
02c7ba73e8 am 41bb0637: am 76e85eec: am 3bc9971d: am 95d6e32b: am 86f9a93e: Merge "Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs" into jb-mr1-dev
* commit '41bb0637ca430808ab40a0300467ea58ae0a05c3':
  Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs
2014-03-25 10:22:56 -07:00
Craig Mautner
95d6e32bc3 am 86f9a93e: Merge "Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs" into jb-mr1-dev
* commit '86f9a93e20bf33b9f5152592f4781bd253be8643':
  Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs
2014-03-25 09:48:27 -07:00
Craig Mautner
0392442de8 Allow FLAG_SHOW_WHEN_LOCKED to apply to dialogs
Previous fix to keep non-show-when-locked windows hid dialogs from
activities that had asked to be show-when-locked. That was too
restrictive.

Fixes bug 13225149.

Change-Id: I39ae9d7cbcc9b5109257f732d027bda3a2de65e4
2014-03-22 17:15:52 -07:00
Adrian Roos
ed529a5a78 am 500ec9ce: am 25fb7133: am 0b2f2122: am d3da8f71: am ecba937b: DO NOT MERGE - Fix keyguard pattern lockout bug
* commit '500ec9ce4b7856eca480c4c7dca8df1211614102':
  DO NOT MERGE - Fix keyguard pattern lockout bug
2014-03-18 13:41:20 -07:00
Adrian Roos
d3da8f711e am ecba937b: DO NOT MERGE - Fix keyguard pattern lockout bug
* commit 'ecba937b005b07d72eadfaf93a200e0b14af2980':
  DO NOT MERGE - Fix keyguard pattern lockout bug
2014-03-18 13:17:12 -07:00
Adrian Roos
ecba937b00 DO NOT MERGE - Fix keyguard pattern lockout bug
(cherry picked from commit 91c9561cbe665f91e1665f30362c409ae180b127)

Bug: 13302967
Change-Id: I35e7319f8767b2320dc11d9bfe8dc034e2a39b28
2014-03-18 18:33:14 +01:00
Craig Mautner
ff89d589c7 Merge commit '3b9de0a4' into manualmerge
Conflicts:
	policy/src/com/android/internal/policy/impl/PhoneWindowManager.java

Change-Id: I5433912e9d97a20bec6c8e287450550daab6d89b
2014-03-13 21:09:35 -07:00
Craig Mautner
1066fc61a3 Resolved conflicts for merge of ad63d914 to jb-mr2-dev
Change-Id: Iea4cec4ce6f588c9f976ac5a1ff0208f1f91471b
2014-03-13 12:35:23 -07:00
Craig Mautner
ad63d91439 am 20a4f490: am 817f5586: am 3d958f81: am 468e8e98: am 1f52437d: Show the keyguard if unsecure window on top
* commit '20a4f490957407b9534fc453833de2fe2f276426':
  Show the keyguard if unsecure window on top
2014-03-13 11:01:13 -07:00
Craig Mautner
468e8e9873 am 1f52437d: Show the keyguard if unsecure window on top
* commit '1f52437de9aa6089a72c7c992f9e7291a6a96115':
  Show the keyguard if unsecure window on top
2014-03-13 10:47:49 -07:00
Craig Mautner
1f52437de9 Show the keyguard if unsecure window on top
When traversing windows save the fact that windows above the topmost
fullscreen window do not hide the lockscreen. If there is such a
window don't show it.

(cherry picked from commit ab55e524b89c13082193940a5bf8480a2c2522d9)

Fixes bug 13225149.

Change-Id: Ib6f33cbcfb2f60d8957a9184729ecdec80c6a236
2014-03-12 22:52:26 +00:00
Craig Mautner
93df07a1b7 Merge "Show the keyguard if unsecure window on top. DO NOT MERGE." into klp-dev 2014-03-07 22:30:26 +00:00
Craig Mautner
2c82c08a54 Show the keyguard if unsecure window on top. DO NOT MERGE.
When traversing windows save the fact that windows above the topmost
fullscreen window do not hide the lockscreen. If there is such a
window don't show it.

Fixes bug 13225149.

Change-Id: Ib6f33cbcfb2f60d8957a9184729ecdec80c6a236
2014-03-07 09:09:27 -08:00
John Spurlock
fee6f69e83 Merge "Volume panel should not clear system ui flags." into klp-dev 2014-03-04 19:09:20 +00:00
John Spurlock
ca4d040342 Volume panel should not clear system ui flags.
Remove private WM flag (used only by the volume panel) to force
the clearable system UI flags clear.

Instead, always lay out the volume panel as if the bars are visible,
as we do for system dialogs - and don't clear the flags.

Reverts part of I25f29af5b6518aba695b64a75977ae240b742118

Bug:11986621
Change-Id: I842729d729d2a6eb2a687d0b930ddb160c6a1b57
2014-03-04 10:12:01 -05:00
John Spurlock
a3e41e7088 Show hideycling for non-primary users.
User 0 owns the window (system_server) but should be allowed
to display on a user's behalf.

Use the corresponding private flag for this system window, since
we cannot classify it by type (TYPE_TOAST) in policy.

Bug:12015090
Change-Id: I33aedb4624288415a5e1ae937676b693024546a9
2014-03-04 10:08:56 -05:00
Jim Miller
e5f17ab5a6 Report keyguard as initially showing and secure until we know
This fixes a bug where an app calls KeyguardManager.isLocked()
before keyguard has had a chance to show.  The fix is to assume
keyguard is showing and secure until we know otherwise.

Fixes bug 11670159

Change-Id: Ifbe4cdf40e3b76d2069ecace940f85fa58f31187
2013-11-13 15:40:48 -08:00
John Spurlock
f92b6161b8 Disallow transient status bar on the keyguard.
FLAG_FULLSCREEN on the app under the keyguard was keeping
the transient status bar visible if the user locked while
revealing it.

Bug:11629810
Change-Id: I034d3a4f4fe5463702253a1fca6d32debd520c3c
2013-11-11 15:01:16 -05:00
John Spurlock
f25706fc3e Fix improperly hidden status bar.
An app lib exposed a possible timing problem, causing the bars
to remain hidden after screen rotation during immersive mode.

Bug:11440463
Change-Id: I5166bdce78a876bc08b18f8b9a340366fbbbb70a
2013-11-07 18:02:43 -05:00
John Spurlock
c23bd80b38 Ensure bar window state is SHOWING after rotate if visible.
Bug:11544694
Change-Id: Ied56f01a931f33437bdc05d026006cabcdef0149
2013-11-06 17:09:51 -05:00
Craig Mautner
81defc794b Force relayout at completion of status bar animation
A final layout pass should be done whenever the status bar has
completed its incoming animation.

Fixes bug 10387660.

Change-Id: I48c19015c53116b58cf73e20be32d1f64dd682ca
2013-10-29 11:32:30 -07:00
John Spurlock
a81736a74d Ensure the simple CAB appears below the status bar.
When the contextual action bar is not in overlay mode,
the screen layout is a linear layout.  (screen_simple.xml)

Ensure the standalone CAB appears below the status bar,
consumes the top offset (to avoid content application below it)
and fill in the status area with a guard view for background
protection.

Bug:10014069
Change-Id: I614f16dfa77367a94808aef54710ffebd66e1ca8
2013-10-22 13:51:52 -04:00
John Spurlock
ae3349e1c3 Move the IME navigation guard view up to decor.
Although the IME windows are now allowed to extend into
the nav bar, some IMEs were making assumptions about
computed insets based on the height of the content view.

So our navigation bar view (opaque view blocking the nav bar
area to avoid the island effect when transparent) needs to live
above the content view in the hierarchy, making the content view
the same height as it was before.

A surgical spot to put the guard view is up at the root view
(PhoneWindow.DecorView).  fitSystemWindows is always called since
this view is not recreated, and the layout is stable: waiting until
the IME is attached to the window is too late to add a guard view.

This is above the screen_* layouts, so will work without having to
touch all of them.  And it only affects windows of TYPE_INPUT_METHOD.

Bug:11237795
Change-Id: I6a93f30aec83f1cecfb854073046cbc87ab4aa66
2013-10-18 18:41:22 -04:00
John Spurlock
ac2d61a2d7 Merge "Do not show immersive mode help in touch exploration mode." into klp-dev 2013-10-18 21:08:58 +00:00
Daniel Sandler
900ece502f Do not show immersive mode help in touch exploration mode.
Bug: 11277364
Change-Id: Ifafcbff38e34c0ef08d9a466d93ce591369183a3
2013-10-18 16:05:07 -04:00
Daniel Sandler
da35dded4d Relayout the immersive cling in the correct thread.
Bug: 11266364
Change-Id: Ia629262ff0c362a5a45b6c5822be080cefcb8c56
2013-10-18 12:05:04 -04:00
Jim Miller
e5f910a667 Fix issue where keyguard adds widgets before the system is ready
While under heavy system load,  keyguard was able to create widgets before
before ActivityManagerService was ready.  The result was a race
between keyguard adding widgets and ActivityManagerService being
ready to send broadcasts.

This fix provides keyguard with an additional signal to know when
the system is booted and widgets are safe to load.

Fixes bug b/11217169

Change-Id: I7a714d65b068678f961e52bdde4e1c20f9c287f0
2013-10-16 19:42:34 -07:00
Craig Mautner
79a0ed5848 Merge "Move the wallpaper beneath the keyguard." into klp-dev 2013-10-14 22:24:44 +00:00
Craig Mautner
5800443e2d Move the wallpaper beneath the keyguard.
If the keyguard is the wallpaper target the wallpaper cannot sit at
the bottom of the stack and must be directly beneath the keyguard.
Otherwise keep it at the bottom of the window stack.

App animations when the keyguard is showing should not be disabled if
the keyguard is also animating.

Fixes bug 10858941.
Fixes bug 10932680.

Change-Id: I8399837f6510ea16003f68b165e67439f3571ef4
2013-10-14 13:52:28 -07:00
Daniel Sandler
dd73ee4d0a Add a config resource to enable translucent bars globally.
Setting config_enableTranslucentDecor to false will not
prevent clients from adding FLAG_TRANSLUCENT_NAVIGATION or
STATUS to the window or using the TransluentDecor themes,
but it will prevent View.STATUS_BAR_TRANSLUCENT and
View.NAVIGATION_BAR_TRANSLUCENT from being propagated to the
SystemUI so these requests will not be honored.

Bug: 11182618
Change-Id: I8be6a3a565acf0987ff12f18f1c7e67c96d563c3
2013-10-14 14:52:44 -04:00
John Spurlock
f1a36648ca Implement new SYSTEM_UI_FLAG_IMMERSIVE_STICKY.
Migrate transient bar mode to IMMERSIVE_STICKY, and
introduce new behavior for IMMERSIVE: namely the
opaque bars are revealed by clearing the flags on swipe.

Remove low-profile optimization that confuses api demos
and other apps using low-profile as a signal.

TransientNavigationConfirmation renamed to
ImmersiveModeConfirmation, and its associated resources,
since the confirmation is now shown when the nav bar is
shown in either of the two immersive modes.

Remove unused Toast.makeBar and associated hidden framework
bits now that the confirmation uses a cling instead.

Bug:11062108
Change-Id: Iae49d31973940b9bee9f5b1827756db5eaa76aa3
2013-10-14 13:11:21 -04:00
Daniel Sandler
b83f5c6a42 Limit transient nav cling to 380dp on large/land devices.
Bug: 11077915
Change-Id: I141a5f3f565109ae5ac9221053e5a4db36633ca7
2013-10-14 09:26:43 -04:00
John Spurlock
47e3de2baa Wire up new hideycling ok button to persist setting.
Otherwise you'll see it every time.

Bug:11077915
Change-Id: I2ec725459f6ec133c1b82e9788a80dede6e87343
2013-10-13 19:20:04 -04:00
Daniel Sandler
a953b6d968 New window cling for immersive mode.
Bug: 11077915
Change-Id: I6858259b31301b76dee81d3e6fbc534c1cdea661
2013-10-13 15:28:19 -04:00
Craig Mautner
5a7831733b Merge "Test for hidden keyguard before waiting for it." into klp-dev 2013-10-12 04:54:42 +00:00
Craig Mautner
6f29590e9a Test for hidden keyguard before waiting for it.
Now that non-null window tokens are coming in in additional situations
(ag/372453) we have to look at whether the keyguard is hidden before
deciding to wait for it.

Fixes bug 1187500.

Change-Id: Ie89d5334ab3d0f5b8f2cf8c87fef84a9b6392b72
2013-10-11 21:43:06 -07:00
Jean-Michel Trivi
7a6ccb8729 Merge "Remote volume changes" into klp-dev 2013-10-11 21:12:22 +00:00
Jean-Michel Trivi
fca1e60323 Remote volume changes
When the user plays media remotely, and presses on the volume
 keys with the screen off, verify whether not only local playback
 is active, but also if remote playback is active to see if
 the volume should be adjusted.
When adjusting the volume with screen off, adjust the remote
 volume if applicable.

When controlling volume, give priority to local media playback.

Bug 11169862

Change-Id: I88a8c003969177d50d4c1569ec6cd2a7c153a341
2013-10-11 11:36:18 -07:00
Craig Mautner
d69417d2f6 Merge "Reduce jank on incoming phone call during dream." into klp-dev 2013-10-11 16:49:55 +00:00
Craig Mautner
2881630af9 Reduce jank on incoming phone call during dream.
- Include dreams in the conditions that disable transition animations.
  This way there is no visibility of activities that are closing
  behind the keyguard when an activity that dismisses the keyguard
  starts up.

- Do not notify the keyguard mediator when the keyguard is dismissed
  because a dream is starting up. This keeps activities from resuming
  just because the keyguard is being dismissed.

Fixes bug 11064847.

Change-Id: I9d32fc96d518b1cdab511e187226a3cb889cf6d4
2013-10-10 20:31:00 -07:00
John Spurlock
f95b89a097 Fix dock rect calculation when nav is translucent.
Make sure the dock rect in PWM takes the nav bar height
into account when translucent.  This forms the basis of
many other window calculations, and has multiple downstream
effects.

Fixing this exposed the fact that the Keyguard was not allowed
to fall into the LAYOUT_HIDE_NAV codepath (since it's not an app
window) - so add TYPE_KEYGUARD to that path.

Bug:11157555
Change-Id: I6b1fc4da973a246b80ec108a561e06f6d8a6a92b
2013-10-10 22:18:56 -04:00
John Spurlock
57beb3b5b3 IME navigation guard implemented as a View.
Instead of a custom onDraw in order to stay 100% in sync with abrupt
layout changes.

Also use the unrestricted layout bottom to avoid unnecessary
fitSystemWindows churn.

Bug:11162351
Change-Id: If9bb9a52d503e348d642bf1238f75c4a418ad805
2013-10-10 12:54:05 -04:00
John Spurlock
65e911261d Merge "Allow IMEs to extend below nav bar, remove SystemUI veto." into klp-dev 2013-10-09 21:57:01 +00:00
John Spurlock
c68d577f29 Allow IMEs to extend below nav bar, remove SystemUI veto.
Layout IMEs below the nav bar, offset by bottom padding and
associated guard rectangle with a black background to ensure
they do not appear as islands during transitions.

This makes it safe to remove the SystemUI forced opaque transition
when showing an IME, making the overall transition less expensive,
quicker and smoother overall.

Bug:11058746
Change-Id: I460912ee7c117480c57b947ed31eca330819f32c
2013-10-09 16:23:15 -04:00
Craig Mautner
e8a057a9ae Merge "Remove overly tight constraint on drawn Keyguard." into klp-dev 2013-10-09 19:10:45 +00:00
Craig Mautner
4e8a19c73a Remove overly tight constraint on drawn Keyguard.
The requirement that a window that is invisible will not be drawn is
incorrect. In particular the test fails before a surface has even been
added (mHasSurface == false) or shown (mPolicyVisibility == false).
This was causing the screen to turn on before Keyguard had been drawn
and exposing surfaces that would have normally remained hidden.

Also, don't pass null into KeyguardServiceDelegate.onShown() or we
will immediately turn the screen on before Keyguard is drawn.

Fixes bug 11062635.

Change-Id: I964c7ef186d0a94678020b9c27ca6b79e5433350
2013-10-08 21:32:37 -07:00
Adam Powell
fd71db8445 Close context menu dialogs if the menu becomes empty
If a view triggers showContextMenu while a context menu is already
shown but contributes no items to the menu the menu dialog would
become empty. Simply close the dialog if this happens.

Bug 11063885

Change-Id: I9e7c96073318c94eda5f1e1c4beb596b3d9da781
2013-10-08 15:20:29 -07:00
John Spurlock
4268600f39 Merge "Translucent sysui flags affect layout." into klp-dev 2013-10-08 18:34:57 +00:00