aboutsummaryrefslogtreecommitdiff
path: root/core/src/main/res
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2017-07-18 20:16:23 -0700
committerGitHub <noreply@github.com>2017-07-18 20:16:23 -0700
commit8f2b5ac043f47cc44f43c3788d1377083fb339a2 (patch)
tree8f91042414de211cbfe67a76298300884f46a765 /core/src/main/res
parent4eee8d59c21b2061b9f5fd0e805ca60ab84c3585 (diff)
downloadkau-8f2b5ac043f47cc44f43c3788d1377083fb339a2.tar.gz
kau-8f2b5ac043f47cc44f43c3788d1377083fb339a2.tar.bz2
kau-8f2b5ac043f47cc44f43c3788d1377083fb339a2.zip
Dev 2.1 (#8)
* Rewrite animation interfaces * Update changelog * Add scale factor for slide * Remove margins in iitems and replace with decorators * Remove mutable list * Switch cardiitem to use lambdas for click * status * Utils update and imagepicker fixes * Remove stringholder * Add fade in fade out * Increment about version * Rename fromedge to direction in javadocs * More logging * Add logging and docs * Make card icons visible * Update email builder and icon padding * Create elastic recycler activity * Fix card iitem * Add lint check and plurals * Inline all the things * Format and sort xml * Update dependencies and increment version
Diffstat (limited to 'core/src/main/res')
-rw-r--r--core/src/main/res/transition/kau_enter_slide_bottom.xml16
-rw-r--r--core/src/main/res/transition/kau_enter_slide_top.xml16
-rw-r--r--core/src/main/res/transition/kau_exit_slide_bottom.xml23
-rw-r--r--core/src/main/res/transition/kau_exit_slide_top.xml23
-rw-r--r--core/src/main/res/values/attr.xml11
-rw-r--r--core/src/main/res/values/dimens.xml1
-rw-r--r--core/src/main/res/values/ids.xml36
-rw-r--r--core/src/main/res/values/strings.xml14
-rw-r--r--core/src/main/res/values/strings_commons.xml27
-rw-r--r--core/src/main/res/values/styles_animations.xml35
-rw-r--r--core/src/main/res/xml/kau_changelog.xml14
11 files changed, 127 insertions, 89 deletions
diff --git a/core/src/main/res/transition/kau_enter_slide_bottom.xml b/core/src/main/res/transition/kau_enter_slide_bottom.xml
index 7eb2097..575e189 100644
--- a/core/src/main/res/transition/kau_enter_slide_bottom.xml
+++ b/core/src/main/res/transition/kau_enter_slide_bottom.xml
@@ -1,20 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
-<!--
- Copyright 2015 Google Inc.
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- -->
-
<transitionSet
xmlns:android="http://schemas.android.com/apk/res/android"
android:transitionOrdering="together"
diff --git a/core/src/main/res/transition/kau_enter_slide_top.xml b/core/src/main/res/transition/kau_enter_slide_top.xml
index 0089b84..8cf613b 100644
--- a/core/src/main/res/transition/kau_enter_slide_top.xml
+++ b/core/src/main/res/transition/kau_enter_slide_top.xml
@@ -1,20 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
-<!--
- Copyright 2015 Google Inc.
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- -->
-
<transitionSet
xmlns:android="http://schemas.android.com/apk/res/android"
android:transitionOrdering="together"
diff --git a/core/src/main/res/transition/kau_exit_slide_bottom.xml b/core/src/main/res/transition/kau_exit_slide_bottom.xml
new file mode 100644
index 0000000..e0967ec
--- /dev/null
+++ b/core/src/main/res/transition/kau_exit_slide_bottom.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<transitionSet
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:transitionOrdering="together"
+ android:interpolator="@android:interpolator/fast_out_linear_in">
+
+ <slide
+ android:slideEdge="bottom"
+ android:duration="400">
+ <targets>
+ <target android:excludeId="@android:id/navigationBarBackground" />
+ <target android:excludeId="@android:id/statusBarBackground" />
+ </targets>
+ </slide>
+
+ <fade android:duration="400">
+ <targets>
+ <target android:targetId="@android:id/navigationBarBackground" />
+ <target android:targetId="@android:id/statusBarBackground" />
+ </targets>
+ </fade>
+
+</transitionSet>
diff --git a/core/src/main/res/transition/kau_exit_slide_top.xml b/core/src/main/res/transition/kau_exit_slide_top.xml
new file mode 100644
index 0000000..a9849c0
--- /dev/null
+++ b/core/src/main/res/transition/kau_exit_slide_top.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<transitionSet
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:transitionOrdering="together"
+ android:interpolator="@android:interpolator/fast_out_linear_in">
+
+ <slide
+ android:slideEdge="top"
+ android:duration="400">
+ <targets>
+ <target android:excludeId="@android:id/navigationBarBackground" />
+ <target android:excludeId="@android:id/statusBarBackground" />
+ </targets>
+ </slide>
+
+ <fade android:duration="400">
+ <targets>
+ <target android:targetId="@android:id/navigationBarBackground" />
+ <target android:targetId="@android:id/statusBarBackground" />
+ </targets>
+ </fade>
+
+</transitionSet>
diff --git a/core/src/main/res/values/attr.xml b/core/src/main/res/values/attr.xml
new file mode 100644
index 0000000..f02c219
--- /dev/null
+++ b/core/src/main/res/values/attr.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8" standalone="no"?>
+<resources xmlns:tools="http://schemas.android.com/tools" tools:ignore="ResourceName">
+ <declare-styleable name="MeasureSpecDelegate">
+ <attr format="float" name="relativeWidth"/>
+ <attr format="float" name="relativeWidthToParent"/>
+ <attr format="float" name="postRelativeWidth"/>
+ <attr format="float" name="relativeHeight"/>
+ <attr format="float" name="relativeHeightToParent"/>
+ <attr format="float" name="postRelativeHeight"/>
+ </declare-styleable>
+</resources>
diff --git a/core/src/main/res/values/dimens.xml b/core/src/main/res/values/dimens.xml
index a459443..b7c237a 100644
--- a/core/src/main/res/values/dimens.xml
+++ b/core/src/main/res/values/dimens.xml
@@ -13,6 +13,7 @@
<dimen name="kau_status_bar_height">24dp</dimen>
<dimen name="kau_drag_dismiss_distance">112dp</dimen> <!-- 2 * ?android:actionBarSize -->
+ <dimen name="kau_drag_dismiss_distance_large">168dp</dimen> <!-- 3 * ?android:actionBarSize -->
<dimen name="kau_spacing_normal">8dp</dimen>
<dimen name="kau_spacing_micro">4dp</dimen>
diff --git a/core/src/main/res/values/ids.xml b/core/src/main/res/values/ids.xml
index 0b4322c..003e8a7 100644
--- a/core/src/main/res/values/ids.xml
+++ b/core/src/main/res/values/ids.xml
@@ -1,19 +1,19 @@
-<?xml version="1.0" encoding="utf-8"?>
+<?xml version="1.0" encoding="utf-8" standalone="no"?>
<resources>
- <item name="kau_item_account" type="id" />
- <item name="kau_item_pref_header" type="id" />
- <item name="kau_item_pref_text" type="id" />
- <item name="kau_item_pref_checkbox" type="id" />
- <item name="kau_item_pref_seekbar" type="id" />
- <item name="kau_item_pref_color_picker" type="id" />
- <item name="kau_item_pref_sub_item" type="id" />
- <item name="kau_item_pref_plain_text" type="id" />
- <item name="kau_item_search" type="id" />
- <item name="kau_item_cutout" type="id" />
- <item name="kau_item_header_big_margin_top" type="id" />
- <item name="kau_item_card" type="id" />
- <item name="kau_item_library" type="id" />
- <item name="kau_item_about_main" type="id" />
- <item name="kau_pref_inner_content" type="id" />
- <item name="kau_pref_lower_content" type="id" />
-</resources> \ No newline at end of file
+ <item name="kau_item_about_main" type="id"/>
+ <item name="kau_item_account" type="id"/>
+ <item name="kau_item_card" type="id"/>
+ <item name="kau_item_cutout" type="id"/>
+ <item name="kau_item_header_big_margin_top" type="id"/>
+ <item name="kau_item_library" type="id"/>
+ <item name="kau_item_pref_checkbox" type="id"/>
+ <item name="kau_item_pref_color_picker" type="id"/>
+ <item name="kau_item_pref_header" type="id"/>
+ <item name="kau_item_pref_plain_text" type="id"/>
+ <item name="kau_item_pref_seekbar" type="id"/>
+ <item name="kau_item_pref_sub_item" type="id"/>
+ <item name="kau_item_pref_text" type="id"/>
+ <item name="kau_item_search" type="id"/>
+ <item name="kau_pref_inner_content" type="id"/>
+ <item name="kau_pref_lower_content" type="id"/>
+</resources>
diff --git a/core/src/main/res/values/strings.xml b/core/src/main/res/values/strings.xml
index 5ea5a23..7ad6e38 100644
--- a/core/src/main/res/values/strings.xml
+++ b/core/src/main/res/values/strings.xml
@@ -1,15 +1,13 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<resources>
- <string name="kau_u2022">•</string>
+ <string name="kau_about_libraries_intro">This app would not be possible without the following great libraries.</string>
<string name="kau_color_picker">Color Picker</string>
-
+ <string name="kau_dependencies_used">Dependencies Used</string>
+ <string name="kau_kpref_title_placeholder">Title Placeholder</string>
+ <string name="kau_md_color_palette">Color Palette</string>
<!--Color Picker-->
<string name="kau_md_custom">Custom</string>
<string name="kau_md_presets">Presets</string>
- <string name="kau_md_color_palette">Color Palette</string>
-
- <string name="kau_kpref_title_placeholder">Title Placeholder</string>
<string name="kau_pref_icon">Pref Icon</string>
-
- <string name="kau_about_libraries_intro">This app would not be possible without the following great libraries.</string>
- <string name="kau_dependencies_used">Dependencies Used</string>
+ <string name="kau_u2022">•</string>
</resources>
diff --git a/core/src/main/res/values/strings_commons.xml b/core/src/main/res/values/strings_commons.xml
index 389b8a2..560a478 100644
--- a/core/src/main/res/values/strings_commons.xml
+++ b/core/src/main/res/values/strings_commons.xml
@@ -1,8 +1,8 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!--
A collection of common string values
Most resources are verbatim and x represents a formatted item
-->
-
<resources>
<string name="kau_about_app">About App</string>
<string name="kau_about_x">About %s</string>
@@ -13,6 +13,7 @@ Most resources are verbatim and x represents a formatted item
<string name="kau_changelog">Changelog</string>
<string name="kau_close">Close</string>
<string name="kau_contact_us">Contact Us</string>
+ <string name="kau_copy">Copy</string>
<string name="kau_custom">Custom</string>
<string name="kau_dark">Dark</string>
<string name="kau_default">Default</string>
@@ -38,8 +39,6 @@ Most resources are verbatim and x represents a formatted item
<string name="kau_no_results_found">No Results Found</string>
<string name="kau_none">None</string>
<string name="kau_ok">@android:string/ok</string>
- <string name="kau_one_day">1 day</string>
- <string name="kau_one_hour">1 hour</string>
<string name="kau_play_store">Play Store</string>
<string name="kau_rate">Rate</string>
<string name="kau_report_bug">Report A Bug</string>
@@ -48,13 +47,25 @@ Most resources are verbatim and x represents a formatted item
<string name="kau_send_via">Send via</string>
<string name="kau_settings">Settings</string>
<string name="kau_share">Share</string>
+ <string name="kau_text_copied">Text copied to clipboard.</string>
<string name="kau_thank_you">Thank You</string>
<string name="kau_uh_oh">Uh Oh</string>
<string name="kau_warning">Warning</string>
- <string name="kau_x_days">%d days</string>
- <string name="kau_x_hours">%d hours</string>
- <string name="kau_x_minutes">%d minutes</string>
+ <plurals name="kau_x_days">
+ <item quantity="one">%d day</item>
+ <item quantity="other">%d days</item>
+ </plurals>
+ <plurals name="kau_x_hours">
+ <item quantity="one">%d hour</item>
+ <item quantity="other">%d hours</item>
+ </plurals>
+ <plurals name="kau_x_minutes">
+ <item quantity="one">%d minute</item>
+ <item quantity="other">%d minutes</item>
+ </plurals>
+ <plurals name="kau_x_seconds">
+ <item quantity="one">%d second</item>
+ <item quantity="other">%d seconds</item>
+ </plurals>
<string name="kau_yes">Yes</string>
- <string name="kau_text_copied">Text copied to clipboard.</string>
- <string name="kau_copy">Copy</string>
</resources>
diff --git a/core/src/main/res/values/styles_animations.xml b/core/src/main/res/values/styles_animations.xml
index a991132..fc872bd 100644
--- a/core/src/main/res/values/styles_animations.xml
+++ b/core/src/main/res/values/styles_animations.xml
@@ -1,4 +1,22 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<resources>
+ <style name="KauFadeIn" parent="@android:style/Animation.Activity">
+ <item name="android:activityOpenEnterAnimation">@anim/kau_fade_in</item>
+ <item name="android:activityCloseEnterAnimation">@anim/kau_fade_in</item>
+ <item name="android:taskOpenEnterAnimation">@anim/kau_fade_in</item>
+ <item name="android:taskCloseEnterAnimation">@anim/kau_fade_in</item>
+ <item name="android:taskToFrontEnterAnimation">@anim/kau_fade_in</item>
+ <item name="android:windowEnterAnimation">@anim/kau_fade_in</item>
+ </style>
+
+ <style name="KauFadeInFadeOut" parent="@style/KauFadeIn">
+ <item name="android:activityOpenExitAnimation">@anim/kau_fade_out</item>
+ <item name="android:activityCloseExitAnimation">@anim/kau_fade_out</item>
+ <item name="android:taskOpenExitAnimation">@anim/kau_fade_out</item>
+ <item name="android:taskCloseExitAnimation">@anim/kau_fade_out</item>
+ <item name="android:taskToFrontExitAnimation">@anim/kau_fade_out</item>
+ <item name="android:windowExitAnimation">@anim/kau_fade_out</item>
+ </style>
<style name="KauSlideIn" parent="@android:style/Animation.Activity">
<item name="android:activityOpenEnterAnimation">@anim/kau_slide_in_right</item>
@@ -9,15 +27,6 @@
<item name="android:windowEnterAnimation">@anim/kau_slide_in_right</item>
</style>
- <style name="KauSlideInSlideOut" parent="@style/KauSlideIn">
- <item name="android:activityOpenExitAnimation">@anim/kau_slide_out_right</item>
- <item name="android:activityCloseExitAnimation">@anim/kau_slide_out_right</item>
- <item name="android:taskOpenExitAnimation">@anim/kau_slide_out_right</item>
- <item name="android:taskCloseExitAnimation">@anim/kau_slide_out_right</item>
- <item name="android:taskToFrontExitAnimation">@anim/kau_slide_out_right</item>
- <item name="android:windowExitAnimation">@anim/kau_slide_out_right</item>
- </style>
-
<style name="KauSlideInFadeOut" parent="@style/KauSlideIn">
<item name="android:activityOpenExitAnimation">@anim/kau_fade_out</item>
<item name="android:activityCloseExitAnimation">@anim/kau_fade_out</item>
@@ -27,4 +36,12 @@
<item name="android:windowExitAnimation">@anim/kau_fade_out</item>
</style>
+ <style name="KauSlideInSlideOut" parent="@style/KauSlideIn">
+ <item name="android:activityOpenExitAnimation">@anim/kau_slide_out_right</item>
+ <item name="android:activityCloseExitAnimation">@anim/kau_slide_out_right</item>
+ <item name="android:taskOpenExitAnimation">@anim/kau_slide_out_right</item>
+ <item name="android:taskCloseExitAnimation">@anim/kau_slide_out_right</item>
+ <item name="android:taskToFrontExitAnimation">@anim/kau_slide_out_right</item>
+ <item name="android:windowExitAnimation">@anim/kau_slide_out_right</item>
+ </style>
</resources>
diff --git a/core/src/main/res/xml/kau_changelog.xml b/core/src/main/res/xml/kau_changelog.xml
deleted file mode 100644
index e570995..0000000
--- a/core/src/main/res/xml/kau_changelog.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<resources>
-
- <!--This is a template-->
-
- <!--
- <version title="v"/>
- <item text="" />
- -->
-
- <version title="v0.1" />
- <item text="Initial Changelog" />
- <item text="" />
-</resources> \ No newline at end of file