112 Commits

Author SHA1 Message Date
travisc
1f58c9f2c3 Bump version to 25.3.0.
PiperOrigin-RevId: 150135802
2017-03-14 17:35:07 -07:00
travisc
395a258bc7 Bump version to 25.2.0.
PiperOrigin-RevId: 150132393
2017-03-14 17:34:29 -07:00
Yuichi Araki
ddcda55a30 Fix restore of actionView state in NavigationView
NavigationView was crashing on restoring its states when an action view
outside the screen gets inside the screen by screen orientation change
or similar.

Test: NavigationViewTest#testActionViewState
Bug: 34796332
Change-Id: Id2c150fce4d6cc4695c50d57523243975c4f2ef0

PiperOrigin-RevId: 150128785
2017-03-14 17:33:48 -07:00
Jonathan Koren
5ec569f17e Fix TabLayout#setScrollPosition() in RTL
Also includes Ib494e97ee482f6b221ad957518af8b4885e88d89, as the added
test fails pre-M otherwise.

Bug: 34686900
Test: Added new test in TabLayoutTest
Change-Id: I2bdee71d55e8b68377124fc4d8a7b94a01a567ba

PiperOrigin-RevId: 149492933
2017-03-14 17:31:48 -07:00
Chris Banes
d5f104f1c8 Fix scroll|enterAlways when we have a top inset
Currently AppBarLayout scrolls too far. This
CL fixes that.

Test: included
BUG: 33934454
Change-Id: Id835c255dddef3ce4fdedd5a4e18a7bd493c5f9a

PiperOrigin-RevId: 149335184
2017-03-14 17:30:49 -07:00
travisc
15f9ce0dd3 Rolling AppBarLayout fixes forward, since the test breakage is now fixed.
PiperOrigin-RevId: 148942854
2017-03-14 17:27:49 -07:00
Chris Banes
db70ec1e76 Rolling back for test breakage.
PiperOrigin-RevId: 148722460
2017-03-14 17:27:23 -07:00
Chris Banes
3fe5df16e1 Fix various AppBarLayout restoration bugs
- Not restoring elevation
- Not restoring on min-height with status bar insets
- Not restoring when expanded="true" set in layout

Test: included
BUG: 33471543
BUG: 33510949
BUG: 33511540
Change-Id: I43b2afeaf1c2cebf0a87045314830064554e2c5d

PiperOrigin-RevId: 148701728
2017-03-14 17:26:55 -07:00
Tenghui Zhu
b31e69875a Mark path as non translatable
Test: Newly added test and sample app for the original repro step.

AOSP bug: https://code.google.com/p/android/issues/detail?id=232407
Bug: 34767250
Change-Id: Ia216bf1177a55a139f8988d995836c1d42c496ee

PiperOrigin-RevId: 147116504
2017-03-14 17:20:10 -07:00
Alan Viverette
8b7af4099b Fix TextInputLayout's hint not expanding
Happens when the EditText is populated with
text from the layout, etc. Caused by some
state being set wrong in the constructor,
which makes the proceeding state update
no-op, since it thinks it is already in the
state.

BUG: 33585556
Test: included
Change-Id: I34c6e9aca3c41f864974ad32fcdbb6dc829645b8

PiperOrigin-RevId: 147067802
2017-02-09 17:32:24 -08:00
travisc
31177ce550 Fix emulator test breakage on API19, due to class loading failure in test coverage classes.
Enabling test coverage on the com.android.test project causes Dalvik to be
upset, and is just unnecessary/not useful, so this turns that off.

Also deletes a couple unneeded configuration statements in the test app that I
had missed cleaning up before.

PiperOrigin-RevId: 146975159
2017-02-08 16:48:31 -08:00
travisc
69a70219ad Restructure emulator tests for better bazel support.
Bazel wants a structure where the application used for testing and the tests themselves are in separate packages (which gradle is less picky about). Android has a gradle plugin for this setup (com.android.test), although it unfortunately has seemingly worse Android Studio support at this point. In any case, this change splits the code up a bit more, into 3 parts:

- lib: the files we actually distribute as a library to end users
- testing: the test application and its custom component subclasses that are tested by the emulator tests
- tests: the actual emulator test code

The structure is a tad strange for typical gradle projects (testing in particular, which has a build.gradle file for each individual Java package, at the same level as the actual source files), but it better matches the conventions of bazel while also avoiding the need for a ton of parallel directory structures at the top level.

Known issues as of this commit:
- Android Studio doesn't think the Java files in testing/ have the right package. I tried to fix this by bumping their java srcDir up to the java/ root and changing the includes, but Android studio seems unable to properly figure that out and instead acted like the Java files didn't exist at all, so I reverted that. We can possibly modify the iml files that get generated, but I'll save this for a follow-up commit since this is already very large.

- Android Studio seems unable to run emulator tests properly (but they work from the command-line). I don't quite know why they fail, but seems like lacking support for the com.android.test plugin. Hopefully this is something we can work around for find a fix for in the near future.

PiperOrigin-RevId: 146940681
2017-02-08 12:53:34 -08:00