1
0
Aidan Follestad 10 жил өмнө
parent
commit
9e46325e72

+ 9 - 4
README.md

@@ -24,7 +24,7 @@ Easily reference the library in your Android projects using this dependency in y
 
 
 ```Gradle
 ```Gradle
 dependencies {
 dependencies {
-    compile 'com.afollestad:material-dialogs:0.7.3.0'
+    compile 'com.afollestad:material-dialogs:0.7.3.1'
 }
 }
 ```
 ```
 
 
@@ -40,6 +40,9 @@ repositories {
 }
 }
 ```
 ```
 
 
+This will reference Bintray's Maven repository that contains material-dialogs directly, rather
+than going through jCenter first.
+
 ---
 ---
 
 
 # What's New
 # What's New
@@ -778,7 +781,7 @@ There's also a global theming attribute as shown in the Global Theming section o
 The code below will show a little indicator in the input dialog that tells the user how many characters they've
 The code below will show a little indicator in the input dialog that tells the user how many characters they've
 typed, and how many more they can type before reaching a certain limit. If they go over that limit,
 typed, and how many more they can type before reaching a certain limit. If they go over that limit,
 the dialog won't allow them to submit the input. It will also color the input field and length indicator
 the dialog won't allow them to submit the input. It will also color the input field and length indicator
-with an error color of your choosing.
+with an error color of your choosing (or the default if you don't specify one).
 
 
 ```java
 ```java
 new MaterialDialog.Builder(this)
 new MaterialDialog.Builder(this)
@@ -792,8 +795,10 @@ new MaterialDialog.Builder(this)
         }).show();
         }).show();
 ```
 ```
 
 
-**Note that `inputMaxLengthRes(int, int)` takes a color resource ID for the second parameter, while
-`inputMaxLength(int, int)` takes a literal color integer for the second parameter. You can use either one.**
+*Note that `inputMaxLengthRes(int, int)` takes a color resource ID for the second parameter, while
+`inputMaxLength(int, int)` takes a literal color integer for the second parameter. You can use either one.
+If you want to use the default error color from the guidelines, you can use `inputMaxLength(int)` which doesn't
+take the second error color parameter*
 
 
 ---
 ---
 
 

+ 2 - 2
library/build.gradle

@@ -9,7 +9,7 @@ android {
         minSdkVersion 8
         minSdkVersion 8
         targetSdkVersion 22
         targetSdkVersion 22
         versionCode 1
         versionCode 1
-        versionName "0.7.3.0"
+        versionName "0.7.3.1"
     }
     }
     lintOptions {
     lintOptions {
         abortOnError false
         abortOnError false
@@ -29,7 +29,7 @@ publish {
     userOrg = 'drummer-aidan'
     userOrg = 'drummer-aidan'
     groupId = 'com.afollestad'
     groupId = 'com.afollestad'
     artifactId = 'material-dialogs'
     artifactId = 'material-dialogs'
-    version = '0.7.3.0'
+    version = '0.7.3.1'
     description = 'A library for implementing Material design styled dialogs across all versions of Android.'
     description = 'A library for implementing Material design styled dialogs across all versions of Android.'
     website = 'https://github.com/afollestad/material-dialogs'
     website = 'https://github.com/afollestad/material-dialogs'
     issueTracker = "${website}/issues"
     issueTracker = "${website}/issues"

+ 2 - 2
sample/build.gradle

@@ -17,8 +17,8 @@ android {
         applicationId "com.afollestad.materialdialogssample"
         applicationId "com.afollestad.materialdialogssample"
         minSdkVersion 9
         minSdkVersion 9
         targetSdkVersion 22
         targetSdkVersion 22
-        versionCode 118
-        versionName "0.7.3.0"
+        versionCode 119
+        versionName "0.7.3.1"
     }
     }
     lintOptions {
     lintOptions {
         abortOnError false
         abortOnError false

BIN
sample/sample.apk


+ 5 - 5
sample/src/main/java/com/afollestad/materialdialogssample/MainActivity.java

@@ -506,10 +506,10 @@ public class MainActivity extends AppCompatActivity implements
 
 
         int widgetColor = ThemeSingleton.get().widgetColor;
         int widgetColor = ThemeSingleton.get().widgetColor;
         MDTintHelper.setTint(checkbox,
         MDTintHelper.setTint(checkbox,
-                widgetColor == 0 ? getResources().getColor(R.color.material_pink_500) : widgetColor);
+                widgetColor == 0 ? getResources().getColor(R.color.material_teal_500) : widgetColor);
 
 
         MDTintHelper.setTint(passwordInput,
         MDTintHelper.setTint(passwordInput,
-                widgetColor == 0 ? getResources().getColor(R.color.material_pink_500) : widgetColor);
+                widgetColor == 0 ? getResources().getColor(R.color.material_teal_500) : widgetColor);
 
 
         dialog.show();
         dialog.show();
         positiveAction.setEnabled(false); // disabled by default
         positiveAction.setEnabled(false); // disabled by default
@@ -518,7 +518,7 @@ public class MainActivity extends AppCompatActivity implements
     private void showCustomWebView() {
     private void showCustomWebView() {
         int accentColor = ThemeSingleton.get().widgetColor;
         int accentColor = ThemeSingleton.get().widgetColor;
         if (accentColor == 0)
         if (accentColor == 0)
-            accentColor = getResources().getColor(R.color.material_pink_500);
+            accentColor = getResources().getColor(R.color.material_teal_500);
 
 
         ChangelogDialog.create(false, accentColor)
         ChangelogDialog.create(false, accentColor)
                 .show(getSupportFragmentManager(), "changelog");
                 .show(getSupportFragmentManager(), "changelog");
@@ -556,7 +556,7 @@ public class MainActivity extends AppCompatActivity implements
                 .titleColorRes(R.color.material_red_400)
                 .titleColorRes(R.color.material_red_400)
                 .contentColorRes(android.R.color.white)
                 .contentColorRes(android.R.color.white)
                 .backgroundColorRes(R.color.material_blue_grey_800)
                 .backgroundColorRes(R.color.material_blue_grey_800)
-                .dividerColorRes(R.color.material_pink_500)
+                .dividerColorRes(R.color.material_teal_500)
                 .btnSelector(R.drawable.md_btn_selector_custom, DialogAction.POSITIVE)
                 .btnSelector(R.drawable.md_btn_selector_custom, DialogAction.POSITIVE)
                 .positiveColor(Color.WHITE)
                 .positiveColor(Color.WHITE)
                 .negativeColorAttr(android.R.attr.textColorSecondaryInverse)
                 .negativeColorAttr(android.R.attr.textColorSecondaryInverse)
@@ -599,7 +599,7 @@ public class MainActivity extends AppCompatActivity implements
                 .inputType(InputType.TYPE_CLASS_TEXT |
                 .inputType(InputType.TYPE_CLASS_TEXT |
                         InputType.TYPE_TEXT_VARIATION_PERSON_NAME |
                         InputType.TYPE_TEXT_VARIATION_PERSON_NAME |
                         InputType.TYPE_TEXT_FLAG_CAP_WORDS)
                         InputType.TYPE_TEXT_FLAG_CAP_WORDS)
-                .inputMaxLength(16, 0)
+                .inputMaxLength(16)
                 .positiveText(R.string.submit)
                 .positiveText(R.string.submit)
                 .input(R.string.input_hint, R.string.input_hint, false, new MaterialDialog.InputCallback() {
                 .input(R.string.input_hint, R.string.input_hint, false, new MaterialDialog.InputCallback() {
                     @Override
                     @Override

+ 1 - 1
sample/src/main/res/values-v21/styles.xml

@@ -4,7 +4,7 @@
     <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
     <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
         <item name="colorPrimary">@color/material_indigo_500</item>
         <item name="colorPrimary">@color/material_indigo_500</item>
         <item name="colorPrimaryDark">@color/material_indigo_600</item>
         <item name="colorPrimaryDark">@color/material_indigo_600</item>
-        <item name="colorAccent">@color/material_pink_500</item>
+        <item name="colorAccent">@color/material_teal_500</item>
 
 
         <item name="android:navigationBarColor">@color/material_indigo_500</item>
         <item name="android:navigationBarColor">@color/material_indigo_500</item>
     </style>
     </style>

+ 1 - 1
sample/src/main/res/values/colors.xml

@@ -4,7 +4,7 @@
     <!-- http://www.google.com/design/spec/style/color.html#color-color-palette -->
     <!-- http://www.google.com/design/spec/style/color.html#color-color-palette -->
     <color name="material_indigo_500">#3F51B5</color>
     <color name="material_indigo_500">#3F51B5</color>
     <color name="material_indigo_600">#3949AB</color>
     <color name="material_indigo_600">#3949AB</color>
-    <color name="material_pink_500">#E91E63</color>
+    <color name="material_teal_500">#009688</color>
     <color name="material_red_400">#EF5350</color>
     <color name="material_red_400">#EF5350</color>
 
 
 </resources>
 </resources>

+ 1 - 1
sample/src/main/res/values/styles.xml

@@ -4,7 +4,7 @@
     <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
     <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
         <item name="colorPrimary">@color/material_indigo_500</item>
         <item name="colorPrimary">@color/material_indigo_500</item>
         <item name="colorPrimaryDark">@color/material_indigo_600</item>
         <item name="colorPrimaryDark">@color/material_indigo_600</item>
-        <item name="colorAccent">@color/material_pink_500</item>
+        <item name="colorAccent">@color/material_teal_500</item>
     </style>
     </style>
 
 
 </resources>
 </resources>