44 Commits

Author SHA1 Message Date
Andrei Stingaceanu
24b2fc718a Support design - fix FAB elevation in API 21
The animations are really broken here. A hacky fix
has been added in the past for versions 22-24 and now
for version 21 just by bluntly set the elevation and
translationZ by respecting the logic in the animations
for 22-24.

Bug: 33126409
Test: identified this bug from an existing test.
Change-Id: I0cba73cda030ef7a66ffad452bc0f14b7687fc52

GitOrigin-RevId=829c95c8a3fd508b798bedff028d7d6b55e16ce5

PiperOrigin-RevId: 141514172
2016-12-12 16:04:41 -08:00
Kirill Grouchnikov
68a3946982 Move the now-deprecated setCallback to Snackbar
This is where it was originally, and this is where it remains
for backwards-compatibility reasons. Also fix broken tests.

Test: run tests in SnackbarTest
Bug: 33192595
Change-Id: I644c03b6a284d7f7177916347c07fc30558e08b8

GitOrigin-RevId=ca9c74379e9fb2b38965253836a2ab0e36990c45

PiperOrigin-RevId: 141514063
2016-12-12 16:04:37 -08:00
Chris Banes
8c25ca9cf7 Merge "Revert "Don't dispatch touch events to Behaviors to all views"" into nyc-support-25.1-dev
GitOrigin-RevId=ab324436c729ab39010d8d6869519d16c7be563b

PiperOrigin-RevId: 141513666
2016-12-12 16:04:32 -08:00
Chris Banes
5c99693046 Fix CoordinatorLayout inset tests
am: f073132a9b

Change-Id: I87fc111451c80b6f010548959350eed613dc1218

GitOrigin-RevId=5449394ea30fd42d5051db1af8843b16b98ba36e

PiperOrigin-RevId: 141513508
2016-12-12 16:04:27 -08:00
Chris Banes
277039d1cc Merge "Fix FAB setBackgroundTintList on L+" into nyc-support-25.1-dev
GitOrigin-RevId=b9d7dba579d112a7f12ae06496a7a1fb1670385e

PiperOrigin-RevId: 141512478
2016-12-12 16:04:23 -08:00
Chris Banes
615d32fc46 Merge "Small TextInputLayout label fixes" into nyc-support-25.1-dev
GitOrigin-RevId=b1d1c0478c81b1319d1c3fb2970e09380adf2091

PiperOrigin-RevId: 141512013
2016-12-12 16:04:19 -08:00
Chris Banes
25d2244fae Don't dispatch touch events to Behaviors to all views
We should only be dispatching these events to
Behaviors with views which are visibile.

BUG: 33134309
Test: included
Change-Id: I3c9b442dfa00bc6e0fbe1e0ea5969536f988e663

GitOrigin-RevId=4a5dd898048a920452692c99896ef8782d71e09b

PiperOrigin-RevId: 141511687
2016-12-12 16:04:14 -08:00
Chris Banes
173e617d9a Possibly fix IllegalArgumentException for dodge insets
am: c3e71f0d47

Change-Id: I791373a8463dd3592334920233f08a9e089eb0ba

GitOrigin-RevId=245f6b0f5f502171d2e0d82df42f5b29895711df

PiperOrigin-RevId: 141511492
2016-12-12 16:04:09 -08:00
Aurimas Liutikas
7cb8a2103f Merge "Clarify how to select BottomNavigationView active item." into nyc-support-25.1-dev
GitOrigin-RevId=b391ed7b980e115ca81841fe7acb5875acc56f5e

PiperOrigin-RevId: 141511341
2016-12-12 16:04:04 -08:00
TreeHugger Robot
10aa01f940 Merge "Update size annotations for compat, design, and appcompat tests." into nyc-support-25.1-dev
GitOrigin-RevId=fa3094f84f696402be1c750540edf091f989f140

PiperOrigin-RevId: 141511210
2016-12-12 16:03:59 -08:00
TreeHugger Robot
5cebd32087 Merge "Fix FAB showing as pressed when the user drags off it" into nyc-support-25.1-dev
GitOrigin-RevId=099115399b63ce5e24da28017a2266379bd26930

PiperOrigin-RevId: 141511120
2016-12-12 16:03:54 -08:00
Alan Viverette
8cd7c9fdc4 Perform API backwards compatibility check as part of support checkApi
Works around Doclava API check limitations in Snackbar and v17 classes.
Removes @removed code. Restores GuidedActionsStylelist API that was
removed without prior deprecation.

Bug: 30434567
Change-Id: I58c8a869f4e620d2aca8765a73105c95c185c791

GitOrigin-RevId=77d397d533d04dfec663939692f2e048a072ee5b

PiperOrigin-RevId: 141510703
2016-12-12 16:03:50 -08:00
TreeHugger Robot
8a34d1903b Merge "Fix accessibility for password toggle button" into nyc-support-25.1-dev
GitOrigin-RevId=ce68d2b2f605e85c22fe6453d10610d2d40d09f1

PiperOrigin-RevId: 141510504
2016-12-12 16:03:46 -08:00
Chris Banes
28d1c53a0d Fix support library tests
Test: fixing tests
Change-Id: Ib5ef1581167905e957317fefad2fe6278918024b

GitOrigin-RevId=ed4cbfed07f596ed7d675e161fea130bfc3e7034

PiperOrigin-RevId: 141510279
2016-12-12 16:03:42 -08:00
Chris Banes
4816edf175 Merge "Don't dispatch nested scroll events to GONE views" into nyc-support-25.1-dev
GitOrigin-RevId=e47578f12b31591ae984b97a9746e6beeaeb093b

PiperOrigin-RevId: 141510105
2016-12-12 16:03:37 -08:00
Aurimas Liutikas
08b847539c Merge "Move from GROUP_ID to LIBRARY_GROUP annotations" into nyc-support-25.1-dev
GitOrigin-RevId=5f39e7d6ab66782c180079750130d0aadedde424

PiperOrigin-RevId: 141509933
2016-12-12 16:03:32 -08:00
Aurimas Liutikas
8f5bfa5881 Fix BottomNavigationMenu item selection via Menu object
am: 69557a3a03

Change-Id: Iaab10e75354d53096958671d18bd47dc07dfdb28

GitOrigin-RevId=b4da44d7478295076c41ad68ffbced62f0e3b8d4

PiperOrigin-RevId: 141509777
2016-12-12 16:03:28 -08:00
Alan Viverette
29d3d012d5 Adds working lint target to support lib build, more workarounds
Explicitly disable on v17 leanback and v7 preference, which need
some work. Suppress issues due to Lint failing to distinguish locally-
defined methods from framework methods.

Depends on fullsdk project, which is NOT in the default checkout.

Bug: 29630077
Test: ./gradlew lint && ./gradlew assemble
Change-Id: If8da576a8f9e2a431bc60a473f0c36054818d7c1

GitOrigin-RevId=af6b251c15dab2237fdf100b5ebb9c0851c2d490

PiperOrigin-RevId: 141509307
2016-12-12 16:03:24 -08:00
Yuichi Araki
5b508e285f Merge "Handle ACTION_DISMISS in BottomSheetDialog" into nyc-support-25.1-dev
GitOrigin-RevId=d91caeb62e0381daae5dde3a3762587e02329f1c

PiperOrigin-RevId: 141508961
2016-12-12 16:03:19 -08:00
Chris Banes
5bdb7a3b41 Revert "Add support lib version meta-data to AndroidManifest.xml"
This reverts commit cdcdfd0a75b595a3f757ee4cad85852edf130d1d.

Change-Id: I51d7c254eed33262d9d91967b7d212ad514db016

GitOrigin-RevId=5ec99dd02a9c7fab574e0eeb713b0b0947a41d33

PiperOrigin-RevId: 141508608
2016-12-12 16:03:15 -08:00
Chris Banes
eecadb18a9 Add support lib version meta-data to AndroidManifest.xml
Any resulting app built with the support lib from
Gradle will have a meta-data tag added to their
AndroidManifest.xml, for example:

<meta-data android:name="android.support.VERSION"
           android:value="25.1.0" />

The value is automatically populated via the magic
of the Gradle build system.

BUG: 32171613
Test: manual (generate APK and inspect in AS APK Analyzer)

Change-Id: I51cf646b32a15d93105560115f1fee2a71d35e35

GitOrigin-RevId=cdcdfd0a75b595a3f757ee4cad85852edf130d1d

PiperOrigin-RevId: 141508186
2016-12-12 16:03:11 -08:00
Chris Banes
dcb687ccad Merge "Update TextInputLayout icon for spec update" into nyc-support-25.1-dev
GitOrigin-RevId=e7f67226a7ce97d1ae0d22b4a4b4e33010db4881

PiperOrigin-RevId: 141507754
2016-12-12 16:03:07 -08:00
Alan Viverette
0ed7e06c94 Merge remote-tracking branch 'goog/master' into ffwd
GitOrigin-RevId=b0ee811d9ded5a8b94c94652c01d5db7b0ce4b51

PiperOrigin-RevId: 141507272
2016-12-12 16:03:00 -08:00
Chris Banes
6e68784cb1 Stop measure/layout on GONE views in CoordinatorLayout
am: 5435163672

Change-Id: Ifabc1403aa3d16ce9eeaf79263dec71b5019f76e

GitOrigin-RevId=5504bf16938b16c0456a52714d2297062fd7cd8e

PiperOrigin-RevId: 141507009
2016-12-12 16:02:56 -08:00
Chris Banes
97fde0f0cd Fix TextInputLayout hint not working in extract mode
am: 5eab26a2b6

Change-Id: I0d07737edb258df66fdcb6ea33a08a27153422da

GitOrigin-RevId=773434a1329c3c4abac61f623dbf390178a96688

PiperOrigin-RevId: 141506225
2016-12-12 16:02:52 -08:00
Aurimas Liutikas
73e50fe61e BottomNavigationView javadoc fix up.
am: e1e8ec0b26

Change-Id: Ib73c34b74e9e6681a4b5b87db0ce462c96e4fd5b

GitOrigin-RevId=417d9281c4a4e35484e0af07ae915e1cac73136d

PiperOrigin-RevId: 141505885
2016-12-12 16:02:48 -08:00
Aurimas Liutikas
17b966635a Add shadow to BottomNavigationView.
am: 7ff7ddcb89

Change-Id: I85aea8320dea1fe8010a6fd5392834a7f53b22a0

GitOrigin-RevId=d484061a5bf1efcc88e349c229e1d1acbb9befae

PiperOrigin-RevId: 141505394
2016-12-12 16:02:43 -08:00
Aurimas Liutikas
d6acdded21 resolve merge conflicts of 9e1bec8 to master
Change-Id: Ia992f6a6995d30961d7a258337102da792561d5f

GitOrigin-RevId=5fa3fd281ab74ca1dbc56550e830fe2ef9682da6

PiperOrigin-RevId: 141505173
2016-12-12 16:02:38 -08:00
TreeHugger Robot
4ef0f07686 Merge "Disable BottomSheetBehaviorTest#testFabVisibility"
GitOrigin-RevId=6143593b72bc7342325aaca2c34db38ef312d482

PiperOrigin-RevId: 141505003
2016-12-12 16:02:34 -08:00
Aurimas Liutikas
b6afbc1f91 Start using return value of OnNavigationItemSelectedListener. am: 578015fc3e am: a502cd075f am: ba4b4c48c7
am: 9fdc2c22a0

Change-Id: Ia9b3c0bd39b7c38beade606f7f311a12bfe5bad8

GitOrigin-RevId=5f006fe9d3c4c9b8883f7755c42fdf3833d6b8a7

PiperOrigin-RevId: 141504385
2016-12-12 16:02:30 -08:00
TreeHugger Robot
2f01207518 Merge "Annotate the last non-annotated support lib tests."
GitOrigin-RevId=5519d1954fb92951db7b9a9fe17f1f168d9dd96d

PiperOrigin-RevId: 141504118
2016-12-12 16:02:26 -08:00
TreeHugger Robot
90a0de4d67 Merge "Annotate support classes with RequiresApi / TargetApi"
GitOrigin-RevId=338f46204a197c6ab6d11d5923dce01346b0e047

PiperOrigin-RevId: 141503856
2016-12-12 16:02:22 -08:00
Yuichi Araki
0fb66fa282 Merge "NavigationView restores state of the headers"
GitOrigin-RevId=ff8c0bdab1c137451bef9ad7a16846ab142f8381

PiperOrigin-RevId: 141503107
2016-12-12 16:02:17 -08:00
Aurimas Liutikas
cab6d0da26 Merge "Do not attempt to update GONE childen of CoordinatorLayout."
GitOrigin-RevId=73c5aabec92eff5417a06f84459d7f39470851e4

PiperOrigin-RevId: 141502378
2016-12-12 16:02:13 -08:00
Kirill Grouchnikov
1c047f4d1d Remove flakiness / race condition in snackbar tests
Instead of artifical timeouts and race condition in waiting
for snackbar's dismissal in a loop, use Espresso's IdlingResource
to reliably wait until the snackbar has been shown or
dismissed.

Also align the API surface of snackbar's callbacks with DrawerLayout's
listeners, allowing registering more than one callback, and removing
registered callbacks.

Bug: 32022732
Test: ./gradlew support-design:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.design.widget.CustomSnackbarTest
Test: ./gradlew support-design:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.design.widget.SnackbarTest
Change-Id: If8f8415b6453d75cb24a022b2d7d676f7649542c

GitOrigin-RevId=8c153ac8980737c4292ae1c019c69471607b3859

PiperOrigin-RevId: 141502000
2016-12-12 16:02:08 -08:00
Chris Banes
c2e6816d6d Merge "Sync password toggle view after being re-enabled"
GitOrigin-RevId=2a6de19abd05a25e956cd9a62e7069480637ccc4

PiperOrigin-RevId: 141501611
2016-12-12 16:02:03 -08:00
Aurimas Liutikas
6c89dd0666 Merge "Remove a few more usages of runOnMainSync in support-design"
GitOrigin-RevId=648fe3e3376bbc9c9c46c429d6079c3d7c5b5569

PiperOrigin-RevId: 141501179
2016-12-12 16:01:58 -08:00
Chet Haase
740739d8bd Clean up BottomBar docs
Test: made sure docs target build, results looked reasonable
Bug: 32270959 clean up example in BottomNavigationView header docs
Change-Id: Ie27b07ae6b34da60942b448e61386f0a254691e5

GitOrigin-RevId=6f51cc026f499c095cb4259c5480eb8c44635ec3

PiperOrigin-RevId: 141500888
2016-12-12 16:01:54 -08:00
Aurimas Liutikas
4ed543653e Merge "Force BottomNavigationView item labels to be singleLine."
GitOrigin-RevId=02df9a239ca934dd45815d6a291707b1a011766e

PiperOrigin-RevId: 141500461
2016-12-12 16:01:50 -08:00
Alan Viverette
2b4d7c79b6 Fix CoordinatorLayout IllegalArgumentException crash am: f42b1d0113 am: 943958d2b3
am: fbeb10907c

Change-Id: Ie3342f649fcbda77f5bcba0b8df2341792fc4c85

GitOrigin-RevId=1f308230a8f1266c27bffc37fbbe7780aacc1ebd

PiperOrigin-RevId: 141499623
2016-12-12 16:01:45 -08:00
Kirill Grouchnikov
b241ff5785 Merge "Support custom views on snackbars"
GitOrigin-RevId=baa44c7e34d35c5aec759edd57a0833e31417379

PiperOrigin-RevId: 141498549
2016-12-12 16:01:41 -08:00
travisc
0cbebc7887 Begin syncing to 25.1.0 design library code.
This CL will look a bit strange, as it reverse some changes that
were already present. Unfortunately the Android auto-merger greatly
confuses our syncing tool, as it effectively creates new commits
that have the same content as old commits, and does so in a
non-linear fashion (e.g. the commit tree in 25.1.0 is not merely
built on top of 25.0.1).

This CL will get us into a state where we're ready to apply the rest
of the 25.1.0 changes in succession, and once that is completed,
we'll be at the correct (matching) state.

GitOrigin-RevId=11a895a323af06c4731e4c64a7ec2c09ac0aaf2f

PiperOrigin-RevId: 141497561
2016-12-12 16:01:37 -08:00
travisc
0625dfe0e9 Setup a basic gradle build.
Any interaction with Maven is missing, and docs/API txt's are not currently
generating. These will be done in future CLs.

PiperOrigin-RevId: 141363143
2016-12-12 16:01:31 -08:00
travisc
5effa7d71f Add gradle wrapper and associated files, restructure top-level directories.
This new structure will allow for a top-level gradle file and a multi-project
build (which is a more typical structure for things). In the future, it will
allow us to place other projects in here as well (such as sample applications).

PiperOrigin-RevId: 141247594
2016-12-12 16:01:26 -08:00