Commit Graph

7788 Commits

Author SHA1 Message Date
Vladislav Kaznacheev
989b58a633 Update pointer icon when View.setPointerIcon is called
Currently the updated pointer icon is only displayed after
the next mouse move.

Bug:27107871
Change-Id: Ieed57b07fe44699735179cf57968a9bb08981396
2016-02-12 16:55:53 -08:00
John Reck
182bd38430 Merge "Include containing window title in SurfaceView's title" into nyc-dev 2016-02-12 22:24:01 +00:00
Jorim Jaggi
e26334ba1a Merge "Handle light status bar for split-screen" into nyc-dev 2016-02-12 03:12:18 +00:00
Phil Weaver
fd32b894ff Merge "Fix ViewPager crash for a11y z order." into nyc-dev 2016-02-11 20:58:31 +00:00
John Reck
afeea9ba50 Include containing window title in SurfaceView's title
Bug: 27135605
Change-Id: I6fa4e84cb95ed6c445d00c89d93a5befbd0197b6
2016-02-11 12:19:25 -08:00
Jorim Jaggi
8690558241 Handle light status bar for split-screen
In split-screen the light status bar flag for one side of the
status bar can be different from the other side.
SYSTEM_UI_FLAG_LIGHT_STATUS_BAR is now reported for both
the fullscreen stack and docked stack, but not anymore in the
"default" SysUI visibility field when reporting a visibility
change to SystemUI. The change also reports the docked stack
and the fullscreen stack bounds, so SystemUI can guard tinting
the icons on whether the icon is one of the areas.

When calculating the light status bar flag in PWM, we keep track
of the top fullscreen opaque window state for the docked and
fullscreen stack separately.

Bug: 24365214
Change-Id: Id2240a86d75bf96e0138ec7652a4793859f56e3c
2016-02-11 12:18:40 -08:00
Phil Weaver
4354b340bb Fix ViewPager crash for a11y z order.
The ViewPager requires measure/layout to initialize a list used
in getChildDrawingOrder, and crashes when this method is called
too early. Protecting against that by assigning a default value
to the drawing order value of AccessibilityNodeInfo if the View
bounds have not yet been set.

Bug: 27076826
Change-Id: Ic42dbb81d15340f6b021626b1c27ad5abce7e7d1
2016-02-10 11:19:52 -08:00
Yohei Yukawa
37db07216e Make InputMethodInfo#isEncryptionAware() strict.
This is a follow up CL to the previous CL [1], which unintentionally
relied on whether the entire application rather than the
InputMethodService is marked to be encryption-aware.  This wasn't
obvious because right now LatinIME is entirely marked to be
encryption-aware, which probably needs to be reconsidered in subsequent
CLs.

This CL drops "encryptionAware" line from InputMethodInfo#dump() as it
is redundant.  The same information is already dumped in the
'ServiceInfo' section.

 [1] Icf921fe3661eccf4a589b08b616d05decc561356
     69811a98f1

Bug: 26279466
Change-Id: I6cea5fe5731f4a6a64ea722b854b99c5154a15ae
2016-02-09 13:39:50 -08:00
Yohei Yukawa
2ba26dd87c Merge changes Icf921fe3,Ie1a8ee22 into nyc-dev
* changes:
  Add a utility method to InputMethodInfo for FBE.
  Fix style issues in InputMethodInfo.java.
2016-02-09 19:49:20 +00:00
Andres Morales
7364905303 Merge "updates to FrameStatsObserver API" into nyc-dev 2016-02-09 19:00:32 +00:00
Andres Morales
910beb8f5d updates to FrameStatsObserver API
- Rename to FrameMetrics to avoid collision with existing
  android.view.FrameStats class
- Make FrameMetricsObserver implementation detail,
  exposing FrameMetricsListener interface as public API
  and wrapping in FrameStatsObserver to maintain state
- Remove dropped frame count call, in favor of passing as
  parameter to callback method.
- Move away from raw timestamp access in favor of Metric IDs
  which represent higher-level, more stable stages in a frame
  lifecycle and match the categories exposed in the onscreen
  bars.
- Support many-to-many Window<->FrameMetricsListener relationship

Change-Id: I00e741d664d4c868b1b6d0131a23f8316bd8c5c2
2016-02-09 10:40:01 -08:00
Yohei Yukawa
69811a98f1 Add a utility method to InputMethodInfo for FBE.
This is another preparation for Bug 26279466.  Whether an input method
is marked to be encryption-aware or not would become the thing here and
there in the Framework code.  Having a utility method and debug info
in dumpsys should make our lives easier.

Bug: 26279466
Change-Id: Icf921fe3661eccf4a589b08b616d05decc561356
2016-02-09 01:10:27 -08:00
Yohei Yukawa
285765014f Fix style issues in InputMethodInfo.java.
This has nothing to do with Bug 26279466 but might be something nice to
fix just as a preparation.

Bug: 26279466
Change-Id: Ie1a8ee2248081a70728c29e52c657b3a0ed919b1
2016-02-09 01:10:17 -08:00
Jorim Jaggi
81ba11eccb Put dismiss end target at navigation bar
This makes the animation when exiting docked mode a bit nicer
when you fling the divider towards to the navigation bar. However,
since the divider ends at the navigation bar, we need to immediately
dismiss it instead of fading out when the divider is fully occluded
by the navigation bar.

Change-Id: Ic5432fd118cb71be36485667b2c537caf5065ce5
2016-02-08 16:54:55 -08:00
John Reck
8f81637a87 Merge "Fix drawing cache on sw drawing" into nyc-dev 2016-02-08 22:46:09 +00:00
John Reck
046bd306e7 Fix drawing cache on sw drawing
Bug: 26644517
Change-Id: Ie087a05e1dbab75040ca39e0c43df985f8afed3e
2016-02-08 14:13:06 -08:00
Robert Carr
e12aece4ca Ensure surfaces stay alive until activity stop.
Prior to this commit in this case of activity pause, with finishing=true
the activity manager will notify us of app visibility and we will begin
an exit animation. When this exit animation finishes, we will destroy
the application surface (unless its eligible for saving). However there
are two cases where this breaks down:

1. The exit animation finishes before the activity thread handles
the stop transition. Many activities stop rendering on Pause
but many do not and it is totally legal to do so. Sometimes this
results in non fatal dequeue buffer errors and sometimes results in
fatal errors with Pixel Buffers, etc...
2. We may resume the activity shortly after asking the window manager
to pause it. If the window wasn't eligible for animation, we will
immediately destroy it after being told of the visibility change
following PAUSE_FINISHING. It's possible for this to complete
before we process the resume. On the other hand the client
happilly processes the resume and transitions back from PAUSE
and then crashes once it attempts to use it's surface.

In this commit we have the activity manager notify the window manager
when an application has actually finished (or we have timed out
waiting). For windows which have not been explicitly removed by the
client, we defer destruction until we have received both this signal
and the animation has completed.

Bug: 26793431
Change-Id: Ib6ee8fbdd1f03450fbbfd62468a19e97774befab
2016-02-08 20:46:53 +00:00
Adam Powell
2af189a0a7 Preserve compatibility for ViewGroup#showContextMenuForChild
Have the new showContextMenuForChild(View, float, float) call through
to the old showContextMenuForChild(View) before recursing up to its
parent. This ensures that existing apps with custom views that
override the old method still get called as expected if they implement
custom behavior.

Unlike some other similar circumstances we aren't implementing this to
be bidirectional as the new behavior doesn't need to be triggered by
invoking the old. If the older method is invoked explicitly we will
still show old-style dialog context menus instead of the newer popup
style since we won't have a good place to visually anchor a popup.

Bug 26919262

Change-Id: Ie09f922d322b5a24789c7867820c4bc43824c385
(cherry picked from commit 759a4c5400)
2016-02-08 18:59:28 +00:00
Doris Liu
43a5591c8d Merge "Revert "Revert "VectorDrawable native rendering - Step 4 of MANY""" 2016-02-05 21:31:06 +00:00
Doris Liu
766431aa57 Revert "Revert "VectorDrawable native rendering - Step 4 of MANY""
This reverts commit 5a11e8d0ba.

Change-Id: I7a48b59c4f930dad65ddc8590c25a12636244ea2
2016-02-04 16:29:51 -08:00
Jorim Jaggi
5bef2fcce8 Merge changes If489d2ba,I1fe12181,Ieb4f586a,Ib51163a0,Ifdfcf3ad, ...
* changes:
  Hide swipe-up gesture behind tuner flag
  When long pressing recents and already docked, undock
  More multi-window fixes
  Use separate flag to suppress resizes
  Only treat "null" bounds as fullscreen
  Exclude stable insets from task config
  Fix bug where surface was not clipped off during resizing
  Fix crash in SysUI when configuration changes
2016-02-04 22:49:52 +00:00
Jorim Jaggi
9511b0f1e9 Fix bug where surface was not clipped off during resizing
When dragging the divider in a way such the task size goes through
the following transition

- Half size
- Full screen
- Half size

the surface wasn't clipped off anymore. This was because in full
screen configuration, computeDragResizing() == false thus when
going full screen -> half size, we reset the draw state to
DRAW_PENDING to get notified when it has finished drawn. However,
this also broke clipping.

In order to fix this, we always put the window into a resizing mode
no matter whether the bounds are fullscreen or not.

However, this introduces an ugly flickering on the navigation bar,
when going into docked mode, because the app doesn't draw navigation
bar background in resize mode.

To fix that, we calculate the presence of navigation bar whether the
window is fullscreen, and not just whether it's resizing. For that,
we need to calculate the presence in BackdropFrameRenderer, by using
the insets just sent by window manager.

Change-Id: Idf56df4ae7fefe67d068bc2eeda8dc4d83bbefb7
2016-02-04 14:36:46 -08:00
Vladislav Kaznacheev
0975a8dda6 Merge "Support resource references in pointerShape attributes." 2016-02-04 21:28:39 +00:00
Doris Liu
5a11e8d0ba Revert "VectorDrawable native rendering - Step 4 of MANY"
b/26949340 and b/26975469, b/26975079 as well 

This reverts commit f276acd984.

Change-Id: I4b55177daf0d289bc03604c71fd4bf579f65073a
2016-02-04 20:59:00 +00:00
John Reck
0a1abd3247 Merge "Have RT drive window positioning" 2016-02-04 19:32:57 +00:00
John Reck
f648108f83 Have RT drive window positioning
Bug: 22802885

Change-Id: I6beed5474d3a943b16e9097f7bd61ce3cbd37505
2016-02-04 11:23:49 -08:00
Selim Cinek
ae7c208adf Merge "Apapted the touch region for notification headers" 2016-02-04 18:30:01 +00:00
Selim Cinek
c1e3a38d29 Merge "Not truncating notification info anymore" 2016-02-04 18:29:41 +00:00
Selim Cinek
4c4c7384d4 Apapted the touch region for notification headers
Also fixed that RTL wasn't working correctly.

Change-Id: I597b346792fc837bb3a6eb5aa2f23c5c47a7cf57
2016-02-03 20:30:21 -08:00
Selim Cinek
413142a1c1 Not truncating notification info anymore
Bug: 26860987
Change-Id: I4803ce93aa6b70a80ebb478cba29bd4b6be2277f
2016-02-03 20:30:20 -08:00
Vladislav Kaznacheev
1ad6ec2054 Support resource references in pointerShape attributes.
Previously pointerShape value could only be one of the
system pointer shape names (such as "hand" or "arrow").

This CL introduces support for such syntax as:
android:pointerShape="@drawable/custom_pointer_icon"

Change-Id: Ic5276da66367fbfb8e6195434421bac0667198c1
2016-02-03 16:12:12 -08:00
Sunny Goyal
40dedd5a97 Merge "Added support for async inflation of RemoteViews" 2016-02-03 19:31:09 +00:00
Doris Liu
a72d52bbed Merge "VectorDrawable native rendering - Step 4 of MANY" 2016-02-03 00:19:22 +00:00
Doris Liu
f276acd984 VectorDrawable native rendering - Step 4 of MANY
This CL runs VectorDrawable animation on RenderThread. The changes in this CL
include:
- Convert all the animators in AnimatorSet for AVD into a set of RenderNodeAnimators.
- Hook up the new animators with RenderThread
- Add drawOp in RecordingCanvas for drawing VD so that during the animation
  on RenderThread, all the property changes on VD can be reflected on the screen.

TODO:
- Implement reverse and reset for AVD.

Change-Id: I2df1d754f2db0ad098d9c15dde4bb2bdfafc2315
2016-02-02 15:04:01 -08:00
Selim Cinek
132876cff9 Merge "RTL for NotificationHeader now working correctly." 2016-02-02 22:54:15 +00:00
Casey Burkhardt
cbfd71c66d Merge "Exposes accessibility importance on AccessibilityNodeInfo" 2016-02-02 02:47:20 +00:00
Casey Burkhardt
e28ec5f056 Merge "Update AccessibilityAction docs" 2016-02-01 23:44:43 +00:00
Jorim Jaggi
ccdab44d25 Merge changes Ie6c1ea33,Id1af37e6,I9c474f7a,I439c9b66
* changes:
  Reset create state in moveTaskToStack
  Divider tuning
  Fix transition to recents in docked mode
  Fix flicker and other weirdness
2016-02-01 22:18:21 +00:00
Michael Lentine
8f2cd95930 Merge "Adding plumbing for passing the lib directory." 2016-02-01 21:28:25 +00:00
Jorim Jaggi
c6c89a8214 Fix transition to recents in docked mode
Transition for non-compatible apps will be handled in a separate CL.

Change-Id: I9c474f7aa394e4f3eacd1845c78bee5874bd8a59
2016-02-01 12:19:53 -08:00
Selim Cinek
cb445686d7 RTL for NotificationHeader now working correctly.
Change-Id: Id5c3a303044a7fa6ff59f056fd0709eb7c4df887
2016-02-01 12:11:19 -08:00
Wale Ogunwale
f6f5f4ed94 Merge "Made some changes to window caption APIs" 2016-02-01 19:06:18 +00:00
Casey Burkhardt
2d80ae4fbb Exposes accessibility importance on AccessibilityNodeInfo
This allows a service configured with FLAG_INCLUDE_NOT_IMPORTANT_VIEWS
to discover which views in the hierarchy were evaluated as important.

Change-Id: Ife9411e41326b4872fc0682773722b9dae7ce994
2016-02-01 10:35:20 -08:00
Wale Ogunwale
3b93a4d351 Renamed Activity class multi-window APIs
As requested by API council.

Bug: 26507736
Change-Id: I2a87c5eb3c1b48d52703103c2a4f72c250a9a827
2016-02-01 06:58:31 -08:00
Michael Lentine
03d8f76836 Adding plumbing for passing the lib directory.
Added call in handleBindApplication which will pass the library path into
HardwareRender which then passes it to libvulkan through ThreadedRenderer's
jni interface.

Change-Id: I7dc1fec9c7a1566716a4501a0d5697ea94e57b53
2016-01-31 15:37:14 -06:00
Casey Burkhardt
7ef48bec6f Update AccessibilityAction docs
Adds info to AccessibilityAction on how the class is typically used.
Also adds a warning to indicate a view must be important for accessibility
in order for the actions on a View to be discovered.

Change-Id: I5a48712e61a2411f331321142df4e5695e002de5
2016-01-31 11:51:09 -08:00
Wale Ogunwale
a504ca3988 Made some changes to window caption APIs
As recommended by API council.

Bug: 26509365
Change-Id: I4efca89e2e14ffcf66ab8372f694e8bbf58d6fef
2016-01-30 16:02:13 -08:00
Wale Ogunwale
b1faf60b89 Use resizeMode integer instead of resizeable boolean.
Changes activity manager and window manager to use resizeMode
as defined by ActivityInfo#resizeMode instead of a boolean.

Bug: 26774816
Change-Id: I8cef46d9fba6bfdd21df7da63ed5d5330ad03d4b
2016-01-29 07:44:33 -08:00
Selim Cinek
acec8ad6cb Merge "Animating the work profile button location now" 2016-01-29 03:04:40 +00:00
Selim Cinek
d0803bb4ad Merge "Fixed a bug with the media notication template" 2016-01-29 03:04:22 +00:00