4b26997eeb6bbb526738bcbfaaa9b7147ba0f4a2 |
|
16-Jul-2015 |
Yohei Yukawa <yukawa@google.com> |
PopupWindow position must be specified in window coordinates. This CL addresses TODOs in Ib641dda49f7ab1c7d60207c36a47767bb408. With this CL the position of PopupWindow is always specified in window-local coordinates even if FloatingToolbar#mParent is not a decor view. Bug: 22335001 Change-Id: I0cdd63a00051fa30981e517c07682075467ac598
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
9b9d2c572fe26ddbdd0aed8b9d5899b0f9b5c08c |
|
16-Jul-2015 |
Yohei Yukawa <yukawa@google.com> |
Fix comment bug in I71a8d356e868dc7715b030ca1078da4ec39368c3. This is a coment-only follow up CL for I71a8d356e868dc7715b030ca, which wrongly changed coordinates from window-local to view-local (relative to FloatingToolbar#mParent) when showing PopupWindow. The position of PopupWindow still needs to be specified in window-local coordinates as we had done before I71a8d356e868dc7715b030ca1078da4ec39368c3. Currently the problem might not be visible to users because 1. FloatingToolbar is not a public API hence all the instances are under our controll. 2. FloatingToolbar#mParent is alwasy initialized with PhoneWindow#getDecorView() for now. Bug: 22335001 Change-Id: Ib641dda49f7ab1c7d60207c36a47767bb408971c
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
bafc908304d49e8f7f7c5e52772c75da66e4daa3 |
|
14-Jul-2015 |
Yohei Yukawa <yukawa@google.com> |
Allow FloatingToolbar to be outside of the attached window. Currently PopupWindow used for the floating toolbar specifies neither FLAG_LAYOUT_NO_LIMITS nor FLAG_LAYOUT_IN_SCREEN. As a result, the floating toolbar can overlap the selected text when the attached window does not have enough height. Here is the repro code. final TextView textView = new TextView(this); textView.setLayoutParams( new ViewGroup.LayoutParams( ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT)); textView.setText("A test sentence."); textView.setTextIsSelectable(true); final AlertDialog dialog = new AlertDialog.Builder(this) .setView(textView) .create(); dialog.getWindow().setGravity(Gravity.BOTTOM) dialog.show(); If you tap a word in the dialog, the floating toolbar unintentionally overlaps the selected text due to the limited height of the AlertDialog. It also turns out that just calling PopupWindow.setClippingEnabled(false) to specify FLAG_LAYOUT_NO_LIMITS is not sufficient and ends up showing the toolbar on the NavBar because we have mistakenly compared bounds in window-local coordinates (e.g. FloatingActionModemContentRectOnWindow) with bounds in screen coordinates (e.g. FloatingActionMode#mScreenRect). Hence the confusion of window-local coordinates and screen coordinates in FloatingToolbar and FloatingToolbar also needs to be addresses. To summarize here are the notable changes in this CL: - Specify FLAG_LAYOUT_NO_LIMITS so that the floating toolbar can be placed outside of the attached window. (We do this with PopupWindow#setClippingEnabled) - Switch to use screen coordinates from window-local coordiantes in FloatingToolbar and FloatingActionMode because some system components such as WindowManager prefer screen coordinates. - Put -OnScreen suffix for Rect and Point variables as long as they are in screen coordinates. Bug: 22335001 Change-Id: I71a8d356e868dc7715b030ca1078da4ec39368c3
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
8747f37383c41805800d208c8a4ebeeebeddf2dc |
|
30-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix Floating toolbar overflow width. Also clean out unused methods. Bug: 22186458 Change-Id: I5ef03cd7938630c0d607b6fecd540f2bd83bbb65
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
c107b0ecdcd4e2f89ae4bec818c3a94f45c3c15e |
|
26-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix FloatingToolbar flicker in reaction to text cursor blink. 1. Reposition the toolbar on predraw only when positioning has changed. 2. Update the toolbar popup's position only if the content rect changed. 3. Fix FloatingToolbarPopup.cancelOverflowAnimations(). The previous implementation wasn't actually cancelling the animation. (1) is enough to fix the bug. But (2) and (3) fix issues in the toolbar directly related to this bug. Bug: 22039189 Change-Id: I84ec793d788f9402a1f8635e68e3344746f6af07
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
079f33bca029c440ec6e788d6b3185f850f57973 |
|
24-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Enforce FloatingToolbar themes. This ensures that theme attribute values that affect the look and feel of the FloatingToolbar views are the ones specified in the framework. The aim is to avoid apps modifying the toolbar's look and feel in unexpected ways by overriding Theme attributes. Bug: 21957785 Change-Id: Idd472b4e8511f0a039cd07f98b1fd3ce93ae97fa
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
9ae95dff1d9dc78ad98b85fbdb79108dd8a09957 |
|
19-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Better FloatingToolbar positioning. -The toolbar is now rendered over the IME. -The toolbar respects the presence of the IME and tries as much as possible not to obstruct it. -The toolbar may obstruct the IME if there is limited space and we can't find a position that won't obstruct the IME. *A side effect of the toolbar over the IME is that TextView handles will also always be rendered over the IME where necessary. This was the previous behavior before the regression. Bug: 17510971 Change-Id: I26a49565bf025d7c007ba6bb80468c4988fcc051
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
6bc12244480fcdeca84080d5382d63eb2b992883 |
|
16-Jun-2015 |
Clara Bayarri <clarabayarri@google.com> |
Fix Select All Option is truncated when device goes from landscape to portrait We were not taking into account configuration changes to update the available space for the toolbar. Bug: 21816857 Change-Id: I0f346e8eecb66ab788d1500239d5c1e020b87f97
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
6d2b75c86d7007512a6ad935e5125b735106d90a |
|
12-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Floating toolbar no longer obstructs the soft keyboard. -The toolbar popupwindow is set to "need" the keyboard -Updated toolbar positioning bounds -Updated toolbar positioning depending on available space Bug: 21304845 Change-Id: I8d8a59ef6ea639b11bb32cfeb6ead52087fb91e4
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
7aa6d0a4b1ec7f75335348a86284d3773cc72f91 |
|
03-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Change FloatingToolbar entry/exit animations to fadeIn/fadeOut. Bug: 21307167 Change-Id: I7f75e064c264666ad0e8f84d5421fcc15176ee3f
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
2fe44efced5ac28bc3e03c9c101644b4ef0134bb |
|
04-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Merge "Also refresh FloatingToolbar for "icon" menu item changes." into mnc-dev
|
e3eb1833503c324127c621d22cbf7ac1729dbc54 |
|
27-May-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix floating toolbar position issues. This CL makes the toolbar respect a viewport specified by the content area (calculated from the globalVisibleRect and windowInsets). By doing this the toolbar positions itself appropraitely avoiding the status and nav bars. Bug: 21324303 Change-Id: I3de9e114194dd43888b7f581ef12c3f8b813b3ca
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
6cb5cc19d467251d2e1e28791bf070f4ea6a2eed |
|
03-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix FloatingToolbar positioning for RTL. -The position of the toolbar was forced to the left side in an attempt to fix an RTL bug. This led to wrong positioning in LTR. This is now fixed by using a dynamic "show" animation that takes into consideration already set positions. -The correct position of the toolbar wasn't recalculated on updates for RTL. This is now fixed. Bug:21455067 Change-Id: I0b31a8fd3c95549f5f10133a47a4d3ef27689010
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
5047132887112df4235beea8ff42a28f1653e202 |
|
01-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Also refresh FloatingToolbar for "icon" menu item changes. Bug: 21512730 Change-Id: I77f62c46e2d2a11e6cb4329fa8b659bb1a97a6b9
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
6c5ac8e9e6b4b06c460cd2231cdeb93b373efe5d |
|
01-Jun-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix FloatingToolbar look and animation for RTL. - Fix positioning issues which causes the toolbar to appear cut since it extends beyond its containing window. - Fix the open/close overflow animations to open to left (instead or right) for RTL. Bug: 21455067 Change-Id: I799b74c67c96b03bca4b2c9fbb6e1165b651ac7f
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
b21562c4655cb8dfb73819b68b7fc8eeeab40dac |
|
20-May-2015 |
Abodunrinwa Toki <toki@google.com> |
Support icons in the FloatingToolbar Bug: 20202541 Change-Id: Id4d27851739ba557c7f7348094d79f0c5f782e6b
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
4ce050bd83b8c311d7cf7b50e0a36a28df68bc4a |
|
19-May-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix wrong delay values for floatingtoolbar.hide/dismiss Change-Id: Ie16b5f49babd0df0c70b188c9637e17c661e029c
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
1b422a95f7a3308359031b960c3b491a7eeec0dd |
|
18-May-2015 |
Abodunrinwa Toki <toki@google.com> |
Merge "Hide the floating toolbar faster." into mnc-dev
|
ffebf68202311963c497f5793e17d7a075706fd6 |
|
12-May-2015 |
Abodunrinwa Toki <toki@google.com> |
Support min/max height for FloatingToolbar overflow. FloatingToolbar overflow now supports a minimum height of 2 items and a maxiumum height of 4 items. As was the behavior before this CL, it prefers to open the overflow above the selection. Change-Id: Ia7f7bf28530d57c036fb74eea0467d6f5704eb4c
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
c0fa6bd7ac8fa8f138c62d734d276e55d600bb6b |
|
05-May-2015 |
Abodunrinwa Toki <toki@google.com> |
Set FloatingToolbar width for portrait and landscape. Bug: 20711006 Change-Id: Iee061a1031406780eb0f85201543b644fbb4d813
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
cdffaa4c5af71b4bd0c99a98d411ee3883ec4733 |
|
06-May-2015 |
Abodunrinwa Toki <toki@google.com> |
Hide the floating toolbar faster. There's a delay in the toolbar dismiss animation to allow for touch feedback ripples to be visible. This is not necessary when hiding the toolbar. This CL removes the delay for hide animation. Change-Id: Ic665f717200cad863327ef495e416c99aafb2dea
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
c23ac32601af1c7a5877d99c221e7e79e0ed1c90 |
|
25-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
DO NOT MERGE: Minor fixes to FloatingToolbar. * Changes to isShowing() method. * Changes to initial content visibility on show(). Change-Id: I1b20cd5a3fc86ae7427b55c44efd3cc1118148ae
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
0ce3e08a8444c73e63a0f733357581fb4409449a |
|
21-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix FloatingToolbar.show() *Finer cancel animation methods so we call only the necessary ones. *Don't set the FloatingToolbarPopup content view's alpha to 0 before showing it's popup window. *FloatingToolbarPopup.dismiss() should run when toolbar is hidden. Bug: 20456876 Change-Id: I2e7ff5f2ec56af2def0976fa8e770c651daaa3a3
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
d5358ffbee845ecb2ab3e1ebdfec3823104c0dd1 |
|
22-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix floating toolbar touchable region bug. The floating toolbar is rendered inside a transparent popup window so that we can have smooth animations inside of the window (NOTE that animating a view and a window at the same time do not work well as both are not in sync.) Having a transparent window implies that we can't get touch events through to the content below the window for areas covered by the transparent window. To handle this issue we "burn a hole" through the window by specifying it's "touchable area". This is done using the mInsetsComputer which is set on the popup window's root view's tree observer. When the popup is dismissed and re-shown, we need to reset the mInsetsComputer as we most likely won't have that root view any longer. Change-Id: I13ea50bc19950180d339d05d82cbee03230e2f05
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
b90443724a5aa563cb81d6e7512329a66e80fa2c |
|
19-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
Fix FloatingToolbar animation interruptions. This CL makes sure animations don't conflict with one another. Cancelling an animation should also set the animating object to the end state. Change-Id: Ib74515bb99090ce11a6ccd840aba0baee9fc1bf5
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
7270d07aab00c30c7f339963d3e9312456a2462e |
|
17-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
Implement FloatingToolbar.hide() Bug: 20148125 Change-Id: I62e43df565801ada8230fc4a8d5d3f9e1fc842df
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
103d48ec09cbaeedf28b66425cde9198f767e0d5 |
|
16-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
Change FloatingToolbar window layout type. Floating toolbar is now rendered as TYPE_APPLICATION_ABOVE_SUB_PANEL. This causes the FloatingToolbar to be rendered in a layer above the text selection handles (at layer TYPE_APPLICATION_SUB_PANEL.) Bug: 20135562 Change-Id: I1484b3493bf4cd98c679eb222270c53daa46cdf4
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
f8e14fd89b63c91ff441765827dda672c67fa1db |
|
14-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
Style floating toolbar. Change-Id: Ib2729992274fc55ce35ffd68d1bed7b02bea89db
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
517adad1c44b40fddba84c067c987d6db3fc5840 |
|
07-Apr-2015 |
Abodunrinwa Toki <toki@google.com> |
FloatingToolbar with overflow. -Implemented the toolbar overflow -Refactored a bit to make the concepts clear and component easier to understand and maintain -Floating toolbar now uses a clipped popup window that allows touch events to go through the transparent parts Change-Id: I84794e45a8a10f004654550fe976585f9e62bdb5
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|
0c7ed2886e6d17cacc9c0eeb2b7036923ef9a6e0 |
|
27-Mar-2015 |
Abodunrinwa Toki <toki@google.com> |
New floating toolbar implementation for secondary action mode views. Change-Id: I04d179576290f1b107b3777287d81f149e16e658
/frameworks/base/core/java/com/android/internal/widget/FloatingToolbar.java
|