A recent change made disabled components traversable by default when
using a screen reader. This change makes TalkBack report such components
as disabled.
With this change disabled components become discoverable by screen
readers, similarly to how OS native user interface components behave by
default.
The KeyboardFocusTraverser will still skip disabled components so this
does not affect keyboard navigation without screen readers.
handlePositionChanged() is called when the window changes z-order, which
may cause a new mouse event to be synthesised if the mouse is over the
window after the z-order is updated. In this situation, we may not have
received a mouse up/down/move event to update the current modifier
flags, so we need to update them ourselves.
This addresses an issue where OpenGL-backed image content could get lost
when putting and Android app into an inactive state. This happens
because the GL context gets destroyed, freeing all associated resources.
The workaround introduced here will listen for OpenGL state-change
events, and attempt to save and restore framebuffer content into main
memory, so that the content can be restored once the app is reactivated.
This reimplements similar functionality to that removed in
d39789b021.
Unlike the previous implementation, this version will still wait for the
mouse to move over the menu before the countdown timer is allowed to
start. This should avoid the situation where menu items are accidentally
triggered on mouse-up, after a menu opens under the pointer in response
to a mouse-down.
ComponentPeer::setAppStyle() will now update the status and navigation
bar foreground colours, with some caveats:
- Status and nav bar backgrounds are now always completely transparent.
- The navigation bar foreground colour can only be changed on Android
API 26 or higher.
- For platforms using gesture controls instead of button controls, the
system automatically determines the colour of the gesture bar. On
those systems, setAppStyle() will only affect the status bar colour.
Regarding didComplete():
When a WebInputStream is destroyed, the thread of execution will wait in
SharedSession::removeTask() until the task is no longer present in the
list of all active tasks. If multiple threads are all waiting in
removeTask(), then all of those threads should wake when the set of
active tasks changes. Waking only a single thread may result in
deadlocks, as that thread's task may not have completed successfully.
Then, the thread that woke up will be forced to sleep again and may not
get another chance to wake.
Regarding didBecomeInvalid():
Normally, didBecomeInvalid() will only be called after the
SharedSession's destructor. If the destructor is running, we may assume
that no other thread can access the SharedSession, so using notify_one()
in didBecomeInvalid() should be sufficient to wake up the destructor's
thread. However, there's a chance that the NSURLSession may be
invalidated unexpectedly (i.e. before the SharedSession's destructor
runs), in which case there may still be threads waiting in removeTask().
In this scenario we need to notify_all() so that all waiting threads are
able to wake and make progress.
This is a different approach to the change introduced in
04f87320d5.
Instead of completely recreating the window, we now just update the
window's style flags. This should ensure that window and component focus
are preserved.
This follows on from the work in
3e70c37ce3.
The previous patch had the intended effect as long as the peer was
recreated after entering kiosk mode. However, for windows initially
created with non-native titlebars, attempting to disable the titlebar
would have no effect.
We now check whether the native style flags would need to change as a
result of changing kiosk mode, and recreate the peer if necessary.