6.6.3 - Alpha2 - 本地化 Material Dialogs (版本 0.9.6.0) 且支持 options 构建选项
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<decelerateInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:factor="1.5" />
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<alpha
|
||||
android:fromAlpha="0.0"
|
||||
android:toAlpha="1.0"
|
||||
android:interpolator="@anim/decelerate_cubic"
|
||||
android:duration="150" />
|
||||
</set>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<alpha
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0"
|
||||
android:interpolator="@anim/decelerate_cubic"
|
||||
android:duration="150" />
|
||||
</set>
|
||||
@@ -0,0 +1,8 @@
|
||||
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:color="?android:colorControlHighlight">
|
||||
|
||||
<item
|
||||
android:id="@android:id/mask"
|
||||
android:drawable="@drawable/md_btn_shape" />
|
||||
|
||||
</ripple>
|
||||
@@ -0,0 +1,8 @@
|
||||
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:color="?android:colorControlHighlight">
|
||||
|
||||
<item
|
||||
android:id="@android:id/mask"
|
||||
android:drawable="@drawable/md_btn_shape" />
|
||||
|
||||
</ripple>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<inset xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:insetBottom="@dimen/md_button_inset_vertical"
|
||||
android:insetLeft="@dimen/md_button_inset_horizontal"
|
||||
android:insetRight="@dimen/md_button_inset_horizontal"
|
||||
android:insetTop="@dimen/md_button_inset_vertical">
|
||||
<shape android:shape="rectangle">
|
||||
<corners android:radius="@dimen/md_action_corner_radius" />
|
||||
<solid android:color="?android:colorButtonNormal" />
|
||||
<padding
|
||||
android:bottom="@dimen/md_button_padding_vertical"
|
||||
android:left="@dimen/md_button_padding_horizontal"
|
||||
android:right="@dimen/md_button_padding_horizontal"
|
||||
android:top="@dimen/md_button_padding_vertical" />
|
||||
</shape>
|
||||
</inset>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="oval">
|
||||
<solid android:color="#BCBCBC" />
|
||||
<size
|
||||
android:width="@dimen/md_simplelist_icon"
|
||||
android:height="@dimen/md_simplelist_icon" />
|
||||
</shape>
|
||||
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<inset xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:insetBottom="@dimen/md_button_inset_vertical"
|
||||
android:insetLeft="@dimen/md_button_inset_horizontal"
|
||||
android:insetRight="@dimen/md_button_inset_horizontal"
|
||||
android:insetTop="@dimen/md_button_inset_vertical">
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/md_action_corner_radius" />
|
||||
<solid android:color="@color/md_btn_selected" />
|
||||
<padding
|
||||
android:bottom="@dimen/md_button_padding_vertical"
|
||||
android:left="@dimen/md_button_padding_horizontal"
|
||||
android:right="@dimen/md_button_padding_horizontal"
|
||||
android:top="@dimen/md_button_padding_vertical" />
|
||||
</shape>
|
||||
</inset>
|
||||
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<inset xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:insetBottom="@dimen/md_button_inset_vertical"
|
||||
android:insetLeft="@dimen/md_button_inset_horizontal"
|
||||
android:insetRight="@dimen/md_button_inset_horizontal"
|
||||
android:insetTop="@dimen/md_button_inset_vertical">
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/md_action_corner_radius" />
|
||||
<solid android:color="@color/md_btn_selected_dark" />
|
||||
<padding
|
||||
android:bottom="@dimen/md_button_padding_vertical"
|
||||
android:left="@dimen/md_button_padding_horizontal"
|
||||
android:right="@dimen/md_button_padding_horizontal"
|
||||
android:top="@dimen/md_button_padding_vertical" />
|
||||
</shape>
|
||||
</inset>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android" android:exitFadeDuration="@android:integer/config_shortAnimTime">
|
||||
|
||||
<item android:drawable="@drawable/md_btn_selected" android:state_focused="true" />
|
||||
<item android:drawable="@drawable/md_btn_selected" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/md_transparent" />
|
||||
|
||||
</selector>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android" android:exitFadeDuration="@android:integer/config_shortAnimTime">
|
||||
|
||||
<item android:drawable="@drawable/md_btn_selected_dark" android:state_focused="true" />
|
||||
<item android:drawable="@drawable/md_btn_selected_dark" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/md_transparent" />
|
||||
|
||||
</selector>
|
||||
BIN
modules/material-dialogs/src/main/res/drawable/md_ic_more.png
Normal file
BIN
modules/material-dialogs/src/main/res/drawable/md_ic_more.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.3 KiB |
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<solid android:color="@color/md_btn_selected" />
|
||||
</shape>
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<solid android:color="@color/md_btn_selected_dark" />
|
||||
</shape>
|
||||
@@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="#ffffff"
|
||||
android:pathData="M20,11H7.83l5.59,-5.59L12,4l-8,8 8,8 1.41,-1.41L7.83,13H20v-2z" />
|
||||
</vector>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android" android:exitFadeDuration="@android:integer/config_shortAnimTime">
|
||||
|
||||
<item android:drawable="@drawable/md_item_selected" android:state_focused="true" />
|
||||
<item android:drawable="@drawable/md_item_selected" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/md_transparent" />
|
||||
|
||||
</selector>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android" android:exitFadeDuration="@android:integer/config_shortAnimTime">
|
||||
|
||||
<item android:drawable="@drawable/md_item_selected_dark" android:state_focused="true" />
|
||||
<item android:drawable="@drawable/md_item_selected_dark" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/md_transparent" />
|
||||
|
||||
</selector>
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<solid android:color="@android:color/transparent" />
|
||||
</shape>
|
||||
@@ -0,0 +1,39 @@
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?selectableItemBackground"
|
||||
android:descendantFocusability="blocksDescendants"
|
||||
android:minHeight="@dimen/md_listitem_height"
|
||||
android:orientation="horizontal"
|
||||
android:paddingEnd="@dimen/md_dialog_frame_margin"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingStart="@dimen/md_dialog_frame_margin"
|
||||
tools:gravity="start|center_vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingBottom="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:paddingEnd="@dimen/md_listitem_control_margin"
|
||||
android:paddingRight="@dimen/md_listitem_control_margin"
|
||||
android:paddingTop="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:textSize="@dimen/md_listitem_textsize"
|
||||
tools:ignore="RtlSymmetry"
|
||||
tools:text="Item"/>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatCheckBox
|
||||
android:id="@+id/md_control"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@null"
|
||||
android:clickable="false"
|
||||
android:focusable="false"
|
||||
android:gravity="center_vertical"
|
||||
android:minHeight="@dimen/md_listitem_height"/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,39 @@
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?selectableItemBackground"
|
||||
android:descendantFocusability="blocksDescendants"
|
||||
android:minHeight="@dimen/md_listitem_height"
|
||||
android:orientation="horizontal"
|
||||
android:paddingEnd="@dimen/md_dialog_frame_margin"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingStart="@dimen/md_dialog_frame_margin"
|
||||
tools:gravity="start|center_vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingBottom="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:paddingEnd="@dimen/md_listitem_control_margin"
|
||||
android:paddingRight="@dimen/md_listitem_control_margin"
|
||||
android:paddingTop="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:textSize="@dimen/md_listitem_textsize"
|
||||
tools:ignore="RtlSymmetry"
|
||||
tools:text="Item"/>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatRadioButton
|
||||
android:id="@+id/md_control"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@null"
|
||||
android:clickable="false"
|
||||
android:focusable="false"
|
||||
android:gravity="center_vertical"
|
||||
android:minHeight="@dimen/md_listitem_height"/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,57 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merge
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
tools:ignore="UnusedAttribute">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Message" />
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@android:id/progress"
|
||||
style="@style/Widget.MaterialProgressBar.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignLeft="@android:id/progress"
|
||||
android:layout_alignStart="@android:id/progress"
|
||||
android:layout_below="@android:id/progress"
|
||||
android:gravity="start"
|
||||
android:minWidth="36dp"
|
||||
android:textAlignment="viewStart"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
android:textStyle="bold"
|
||||
tools:text="100%" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_minMax"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignEnd="@android:id/progress"
|
||||
android:layout_alignRight="@android:id/progress"
|
||||
android:layout_below="@android:id/progress"
|
||||
android:gravity="end"
|
||||
android:minWidth="48dp"
|
||||
android:textAlignment="viewEnd"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="100%" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</merge>
|
||||
@@ -0,0 +1,34 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingTop="@dimen/md_content_padding_top"
|
||||
android:paddingBottom="@dimen/md_content_padding_top"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:gravity="start|center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@android:id/progress"
|
||||
style="@style/Widget.MaterialProgressBar.ProgressBar"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:indeterminate="true" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingStart="16dp"
|
||||
android:paddingLeft="16dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:gravity="start"
|
||||
android:textAlignment="viewStart"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="NewApi,RtlSymmetry,UnusedAttribute"
|
||||
tools:text="Message" />
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merge
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
tools:ignore="UnusedAttribute">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Message" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@android:id/progress"
|
||||
style="@style/Widget.MaterialProgressBar.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:indeterminate="true" />
|
||||
|
||||
</merge>
|
||||
@@ -0,0 +1,33 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:md_reduce_padding_no_title_no_buttons="false">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<ScrollView
|
||||
android:id="@+id/md_contentScrollView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToPadding="false"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Content"/>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,53 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:md_reduce_padding_no_title_no_buttons="false">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ScrollView
|
||||
android:id="@+id/md_contentScrollView"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToPadding="false"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/md_content_padding_top"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Content"/>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/md_promptCheckbox"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="start"
|
||||
android:layout_marginLeft="@dimen/md_notitle_vertical_padding"
|
||||
android:layout_marginRight="@dimen/md_notitle_vertical_padding"
|
||||
android:focusable="true"
|
||||
android:gravity="start|center_vertical"
|
||||
tools:text="Don't ask again"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/md_stub_colorchooser_grid" />
|
||||
|
||||
<include
|
||||
layout="@layout/md_stub_colorchooser_custom"
|
||||
android:visibility="gone" />
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
</ScrollView>
|
||||
@@ -0,0 +1,17 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/md_root"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/md_customViewFrame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,72 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:md_reduce_padding_no_title_no_buttons="false">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="@dimen/md_content_padding_bottom"
|
||||
android:layout_marginTop="4dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="UnusedAttribute"
|
||||
tools:text="Message"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<EditText
|
||||
android:id="@android:id/input"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="1dp"
|
||||
android:layout_marginLeft="-2dp"
|
||||
android:layout_marginRight="-2dp"
|
||||
android:focusable="true"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="TextFields"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_minMax"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignEnd="@android:id/input"
|
||||
android:layout_alignRight="@android:id/input"
|
||||
android:layout_below="@android:id/input"
|
||||
android:fontFamily="sans-serif"
|
||||
android:gravity="end"
|
||||
android:minWidth="48dp"
|
||||
android:paddingEnd="4dp"
|
||||
android:paddingRight="4dp"
|
||||
android:textAlignment="viewEnd"
|
||||
android:textSize="12sp"
|
||||
tools:ignore="RtlSymmetry,UnusedAttribute"
|
||||
tools:text="50/100"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,84 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:md_reduce_padding_no_title_no_buttons="false">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="@dimen/md_content_padding_bottom"
|
||||
android:layout_marginLeft="@dimen/md_dialog_frame_margin"
|
||||
android:layout_marginRight="@dimen/md_dialog_frame_margin"
|
||||
android:layout_marginTop="4dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="UnusedAttribute"
|
||||
tools:text="Message"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/md_dialog_frame_margin"
|
||||
android:layout_marginRight="@dimen/md_dialog_frame_margin">
|
||||
|
||||
<EditText
|
||||
android:id="@android:id/input"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="1dp"
|
||||
android:layout_marginLeft="-2dp"
|
||||
android:layout_marginRight="-2dp"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="TextFields"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_minMax"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignEnd="@android:id/input"
|
||||
android:layout_alignRight="@android:id/input"
|
||||
android:layout_below="@android:id/input"
|
||||
android:fontFamily="sans-serif"
|
||||
android:gravity="end"
|
||||
android:minWidth="48dp"
|
||||
android:paddingEnd="4dp"
|
||||
android:paddingRight="4dp"
|
||||
android:textAlignment="viewEnd"
|
||||
android:textSize="12sp"
|
||||
tools:ignore="RtlSymmetry,UnusedAttribute"
|
||||
tools:text="50/100"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/md_promptCheckbox"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="start|center_vertical"
|
||||
android:layout_marginLeft="@dimen/md_notitle_vertical_padding_more"
|
||||
android:layout_marginRight="@dimen/md_notitle_vertical_padding_more"
|
||||
android:focusable="true"
|
||||
android:gravity="start"
|
||||
tools:text="Don't ask again"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,55 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe_lesspadding"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ScrollView
|
||||
android:id="@+id/md_contentScrollView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToPadding="false">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_content_padding_top"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Content"/>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/md_contentListViewFrame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/md_contentRecyclerView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToPadding="false"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingTop="@dimen/md_content_padding_top"
|
||||
android:scrollbarStyle="outsideOverlay"
|
||||
android:scrollbars="vertical"/>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,66 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe_lesspadding"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ScrollView
|
||||
android:id="@+id/md_contentScrollView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToPadding="false">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_content_padding_top"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Content"/>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/md_contentListViewFrame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/md_contentRecyclerView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:clipToPadding="false"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingTop="@dimen/md_content_padding_top"
|
||||
android:scrollbarStyle="outsideOverlay"
|
||||
android:scrollbars="vertical"/>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/md_promptCheckbox"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="start"
|
||||
android:layout_marginLeft="@dimen/md_notitle_vertical_padding"
|
||||
android:layout_marginRight="@dimen/md_notitle_vertical_padding"
|
||||
android:focusable="true"
|
||||
android:gravity="start|center_vertical"
|
||||
tools:text="Don't ask again"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,27 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:md_reduce_padding_no_title_no_buttons="false">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<include layout="@layout/md_stub_progress"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,15 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:md_reduce_padding_no_title_no_buttons="false">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<include layout="@layout/md_stub_progress_indeterminate"/>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
@@ -0,0 +1,27 @@
|
||||
<com.afollestad.materialdialogs.internal.MDRootLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:md_reduce_padding_no_title_no_buttons="false">
|
||||
|
||||
<include layout="@layout/md_stub_titleframe"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<include layout="@layout/md_stub_progress_indeterminate_horizontal"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<include layout="@layout/md_stub_actionbuttons"/>
|
||||
|
||||
</com.afollestad.materialdialogs.internal.MDRootLayout>
|
||||
27
modules/material-dialogs/src/main/res/layout/md_listitem.xml
Normal file
27
modules/material-dialogs/src/main/res/layout/md_listitem.xml
Normal file
@@ -0,0 +1,27 @@
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?selectableItemBackground"
|
||||
android:focusable="true"
|
||||
android:gravity="center_vertical|start"
|
||||
android:minHeight="@dimen/md_listitem_height"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="start"
|
||||
android:layout_marginEnd="@dimen/md_dialog_frame_margin"
|
||||
android:layout_marginLeft="@dimen/md_listitem_margin_left"
|
||||
android:layout_marginRight="@dimen/md_dialog_frame_margin"
|
||||
android:layout_marginStart="@dimen/md_listitem_margin_left"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingBottom="@dimen/md_listitem_vertical_margin"
|
||||
android:paddingTop="@dimen/md_listitem_vertical_margin"
|
||||
android:textSize="@dimen/md_listitem_textsize"
|
||||
tools:text="Item"/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,40 @@
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?selectableItemBackground"
|
||||
android:descendantFocusability="blocksDescendants"
|
||||
android:focusable="true"
|
||||
android:minHeight="@dimen/md_listitem_height"
|
||||
android:orientation="horizontal"
|
||||
android:paddingEnd="@dimen/md_dialog_frame_margin"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingStart="@dimen/md_dialog_frame_margin"
|
||||
tools:gravity="start|center_vertical">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatCheckBox
|
||||
android:id="@+id/md_control"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@null"
|
||||
android:clickable="false"
|
||||
android:focusable="false"
|
||||
android:gravity="center_vertical"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_vertical"
|
||||
android:minHeight="@dimen/md_listitem_height"
|
||||
android:paddingBottom="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:paddingLeft="@dimen/md_listitem_control_margin"
|
||||
android:paddingStart="@dimen/md_listitem_control_margin"
|
||||
android:paddingTop="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:textSize="@dimen/md_listitem_textsize"
|
||||
tools:ignore="NewApi,RtlSymmetry"
|
||||
tools:text="Item"/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,40 @@
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?selectableItemBackground"
|
||||
android:descendantFocusability="blocksDescendants"
|
||||
android:focusable="true"
|
||||
android:minHeight="@dimen/md_listitem_height"
|
||||
android:orientation="horizontal"
|
||||
android:paddingEnd="@dimen/md_dialog_frame_margin"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingStart="@dimen/md_dialog_frame_margin"
|
||||
tools:gravity="start|center_vertical">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatRadioButton
|
||||
android:id="@+id/md_control"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@null"
|
||||
android:clickable="false"
|
||||
android:focusable="false"
|
||||
android:gravity="center_vertical"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_vertical"
|
||||
android:minHeight="@dimen/md_listitem_height"
|
||||
android:paddingBottom="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:paddingLeft="@dimen/md_listitem_control_margin"
|
||||
android:paddingStart="@dimen/md_listitem_control_margin"
|
||||
android:paddingTop="@dimen/md_listitem_vertical_margin_choice"
|
||||
android:textSize="@dimen/md_listitem_textsize"
|
||||
tools:ignore="NewApi,RtlSymmetry"
|
||||
tools:text="Item"/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,74 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:baselineAligned="false"
|
||||
android:gravity="center_vertical"
|
||||
android:minHeight="?android:attr/listPreferredItemHeight"
|
||||
android:orientation="horizontal"
|
||||
android:paddingEnd="?android:attr/scrollbarSize"
|
||||
android:paddingRight="?android:attr/scrollbarSize"
|
||||
tools:ignore="RtlSymmetry,UnusedAttribute">
|
||||
|
||||
<ImageView
|
||||
android:id="@android:id/icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginLeft="@dimen/md_preference_content_inset"
|
||||
android:layout_marginStart="@dimen/md_preference_content_inset"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="left|start|center_vertical"
|
||||
android:layout_marginBottom="12dip"
|
||||
android:layout_marginEnd="6dip"
|
||||
android:layout_marginLeft="@dimen/md_preference_content_inset"
|
||||
android:layout_marginRight="6dip"
|
||||
android:layout_marginStart="@dimen/md_preference_content_inset"
|
||||
android:layout_marginTop="12dip"
|
||||
android:layout_weight="1">
|
||||
|
||||
<TextView
|
||||
android:id="@android:id/title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_alignParentStart="true"
|
||||
android:ellipsize="marquee"
|
||||
android:fadingEdge="horizontal"
|
||||
android:fontFamily="sans-serif"
|
||||
android:lines="1"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="16sp"
|
||||
tools:text="Title" />
|
||||
|
||||
<TextView
|
||||
android:id="@android:id/summary"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignLeft="@android:id/title"
|
||||
android:layout_alignStart="@android:id/title"
|
||||
android:layout_below="@android:id/title"
|
||||
android:layout_marginTop="2dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:maxLines="4"
|
||||
android:textColor="?android:textColorSecondary"
|
||||
android:textSize="14sp"
|
||||
tools:text="Summary" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<!-- Preference should place its actual preference widget here. -->
|
||||
<LinearLayout
|
||||
android:id="@android:id/widget_frame"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="end|right|center_vertical"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="vertical" />
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?selectableItemBackground"
|
||||
android:focusable="true"
|
||||
android:gravity="start|center_vertical"
|
||||
android:minHeight="@dimen/md_simpleitem_height"
|
||||
android:orientation="horizontal"
|
||||
android:paddingEnd="@dimen/md_dialog_frame_margin"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingStart="@dimen/md_dialog_frame_margin">
|
||||
|
||||
<ImageView
|
||||
android:id="@android:id/icon"
|
||||
android:layout_width="@dimen/md_simplelist_icon"
|
||||
android:layout_height="@dimen/md_simplelist_icon"
|
||||
android:layout_gravity="start|center_vertical"
|
||||
android:layout_marginEnd="@dimen/md_simplelist_icon_margin"
|
||||
android:layout_marginRight="@dimen/md_simplelist_icon_margin"
|
||||
android:background="@drawable/gray_circle"
|
||||
android:scaleType="fitXY"
|
||||
tools:background="#f5f5f5"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@android:id/title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:textSize="@dimen/md_simplelist_textsize"
|
||||
tools:text="Title" />
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,24 @@
|
||||
<merge
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<com.afollestad.materialdialogs.internal.MDButton
|
||||
android:id="@+id/md_buttonDefaultNeutral"
|
||||
style="@style/MD_ActionButton.Text"
|
||||
tools:text="Neutral"/>
|
||||
|
||||
<com.afollestad.materialdialogs.internal.MDButton
|
||||
android:id="@+id/md_buttonDefaultNegative"
|
||||
style="@style/MD_ActionButton.Text"
|
||||
tools:layout_alignParentLeft="true"
|
||||
tools:layout_alignParentStart="true"
|
||||
tools:text="Negative"/>
|
||||
|
||||
<com.afollestad.materialdialogs.internal.MDButton
|
||||
android:id="@+id/md_buttonDefaultPositive"
|
||||
style="@style/MD_ActionButton.Text"
|
||||
tools:layout_alignParentLeft="true"
|
||||
tools:layout_alignParentStart="true"
|
||||
tools:text="Positive"/>
|
||||
|
||||
</merge>
|
||||
@@ -0,0 +1,235 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/md_colorChooserCustomFrame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="@dimen/md_title_frame_margin_bottom"
|
||||
android:paddingTop="@dimen/md_title_frame_margin_bottom">
|
||||
|
||||
<View
|
||||
android:id="@+id/md_colorIndicator"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="120dp"
|
||||
tools:background="@color/md_material_blue_600" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="@dimen/md_title_frame_margin_bottom"
|
||||
android:gravity="center">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="2dp"
|
||||
android:layout_marginRight="2dp"
|
||||
android:digits="0123456789abcdefABCDEF"
|
||||
android:text="#"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textColorHint="?android:textColorSecondary"
|
||||
android:textSize="@dimen/md_title_textsize"
|
||||
tools:ignore="HardcodedText,TextViewEdits" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/md_hexInput"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:digits="0123456789abcdefABCDEF"
|
||||
android:focusable="true"
|
||||
android:hint="FF0099CC"
|
||||
android:textSize="@dimen/md_title_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/md_title_frame_margin_bottom"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin">
|
||||
|
||||
<!-- Alpha -->
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorALabel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorA"
|
||||
android:layout_alignTop="@+id/md_colorA"
|
||||
android:layout_marginEnd="4dp"
|
||||
android:layout_marginRight="4dp"
|
||||
android:text="A"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/md_colorA"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/md_title_frame_margin_bottom"
|
||||
android:layout_toEndOf="@+id/md_colorALabel"
|
||||
android:layout_toLeftOf="@+id/md_colorAValue"
|
||||
android:layout_toRightOf="@+id/md_colorALabel"
|
||||
android:layout_toStartOf="@+id/md_colorAValue"
|
||||
android:focusable="true"
|
||||
android:max="255" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorAValue"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorA"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignTop="@+id/md_colorA"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:layout_marginStart="4dp"
|
||||
android:gravity="center"
|
||||
android:minWidth="24dp"
|
||||
android:text="0"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<!-- Red -->
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorRLabel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorR"
|
||||
android:layout_alignTop="@+id/md_colorR"
|
||||
android:layout_marginEnd="4dp"
|
||||
android:layout_marginRight="4dp"
|
||||
android:text="R"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/md_colorR"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/md_colorA"
|
||||
android:layout_marginTop="@dimen/md_title_frame_margin_bottom"
|
||||
android:layout_toEndOf="@+id/md_colorRLabel"
|
||||
android:layout_toLeftOf="@+id/md_colorRValue"
|
||||
android:layout_toRightOf="@+id/md_colorRLabel"
|
||||
android:layout_toStartOf="@+id/md_colorRValue"
|
||||
android:focusable="true"
|
||||
android:max="255" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorRValue"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorR"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignTop="@+id/md_colorR"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:layout_marginStart="4dp"
|
||||
android:gravity="center"
|
||||
android:minWidth="24dp"
|
||||
android:text="0"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<!-- Green -->
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorGLabel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorG"
|
||||
android:layout_alignTop="@+id/md_colorG"
|
||||
android:layout_marginEnd="4dp"
|
||||
android:layout_marginRight="4dp"
|
||||
android:text="G"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/md_colorG"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/md_colorR"
|
||||
android:layout_marginTop="@dimen/md_title_frame_margin_bottom"
|
||||
android:layout_toEndOf="@+id/md_colorGLabel"
|
||||
android:layout_toLeftOf="@+id/md_colorGValue"
|
||||
android:layout_toRightOf="@+id/md_colorGLabel"
|
||||
android:layout_toStartOf="@+id/md_colorGValue"
|
||||
android:focusable="true"
|
||||
android:max="255" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorGValue"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorG"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignTop="@+id/md_colorG"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:layout_marginStart="4dp"
|
||||
android:gravity="center"
|
||||
android:minWidth="24dp"
|
||||
android:text="0"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<!-- Blue -->
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorBLabel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorB"
|
||||
android:layout_alignTop="@+id/md_colorB"
|
||||
android:layout_marginEnd="4dp"
|
||||
android:layout_marginRight="4dp"
|
||||
android:text="B"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/md_colorB"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/md_colorG"
|
||||
android:layout_marginTop="@dimen/md_title_frame_margin_bottom"
|
||||
android:layout_toEndOf="@+id/md_colorBLabel"
|
||||
android:layout_toLeftOf="@+id/md_colorBValue"
|
||||
android:layout_toRightOf="@+id/md_colorBLabel"
|
||||
android:layout_toStartOf="@+id/md_colorBValue"
|
||||
android:max="255" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_colorBValue"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@+id/md_colorB"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignTop="@+id/md_colorB"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:layout_marginStart="4dp"
|
||||
android:gravity="center"
|
||||
android:minWidth="24dp"
|
||||
android:text="0"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.afollestad.materialdialogs.color.FillGridView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/md_grid"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:clipToPadding="false"
|
||||
android:columnWidth="@dimen/md_colorchooser_circlesize"
|
||||
android:gravity="center"
|
||||
android:horizontalSpacing="8dp"
|
||||
android:numColumns="auto_fit"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp"
|
||||
android:stretchMode="columnWidth"
|
||||
android:verticalSpacing="8dp" />
|
||||
@@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="start"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="@dimen/md_content_padding_bottom"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<TextView
|
||||
android:id="@android:id/message"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="@dimen/md_content_padding_bottom"
|
||||
android:layout_marginTop="4dp"
|
||||
android:focusable="true"
|
||||
android:fontFamily="sans-serif"
|
||||
android:paddingLeft="2dp"
|
||||
android:paddingRight="2dp"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="UnusedAttribute"
|
||||
tools:text="Message" />
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,58 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merge
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
tools:ignore="UnusedAttribute">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Message"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@android:id/progress"
|
||||
style="?android:progressBarStyleHorizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="2dp"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignLeft="@android:id/progress"
|
||||
android:layout_alignStart="@android:id/progress"
|
||||
android:layout_below="@android:id/progress"
|
||||
android:gravity="start"
|
||||
android:minWidth="36dp"
|
||||
android:textAlignment="viewStart"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
android:textStyle="bold"
|
||||
tools:text="100%"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_minMax"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignEnd="@android:id/progress"
|
||||
android:layout_alignRight="@android:id/progress"
|
||||
android:layout_below="@android:id/progress"
|
||||
android:gravity="end"
|
||||
android:minWidth="48dp"
|
||||
android:textAlignment="viewEnd"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="100%"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</merge>
|
||||
@@ -0,0 +1,33 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="start|center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingBottom="@dimen/md_content_padding_top"
|
||||
android:paddingLeft="@dimen/md_dialog_frame_margin"
|
||||
android:paddingRight="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_content_padding_top">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@android:id/progress"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:indeterminate="true"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:fontFamily="sans-serif"
|
||||
android:gravity="start"
|
||||
android:paddingLeft="16dp"
|
||||
android:paddingStart="16dp"
|
||||
android:textAlignment="viewStart"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:ignore="NewApi,RtlSymmetry,UnusedAttribute"
|
||||
tools:text="Message"/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merge
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
tools:ignore="UnusedAttribute">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:fontFamily="sans-serif"
|
||||
android:textSize="@dimen/md_content_textsize"
|
||||
tools:text="Message"/>
|
||||
|
||||
<ProgressBar
|
||||
android:id="@android:id/progress"
|
||||
style="?android:progressBarStyleHorizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="2dp"/>
|
||||
|
||||
</merge>
|
||||
@@ -0,0 +1,48 @@
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/md_titleFrame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:baselineAligned="false"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_dialog_frame_margin"
|
||||
android:paddingEnd="0dp"
|
||||
android:paddingBottom="@dimen/md_title_frame_margin_bottom">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/md_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/md_icon_margin"
|
||||
android:scaleType="fitXY"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_title"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical"
|
||||
android:textSize="@dimen/md_title_textsize"
|
||||
tools:text="Title" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/md_options"
|
||||
android:layout_width="47dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:maxHeight="47dp"
|
||||
android:paddingTop="4dp"
|
||||
android:paddingStart="5dp"
|
||||
android:paddingEnd="20dp"
|
||||
android:src="@drawable/md_ic_more"
|
||||
android:visibility="gone"
|
||||
app:tint="?android:attr/textColorPrimary"
|
||||
tools:ignore="ContentDescription"
|
||||
tools:visibility="visible" />
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,48 @@
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/md_titleFrame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:baselineAligned="false"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="@dimen/md_dialog_frame_margin"
|
||||
android:paddingTop="@dimen/md_dialog_frame_margin"
|
||||
android:paddingEnd="0dp"
|
||||
android:paddingBottom="@dimen/md_title_frame_margin_bottom_less">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/md_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/md_icon_margin"
|
||||
android:scaleType="fitXY"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/md_title"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical"
|
||||
android:textSize="@dimen/md_title_textsize"
|
||||
tools:text="Title" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/md_options"
|
||||
android:layout_width="47dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:maxHeight="47dp"
|
||||
android:paddingTop="4dp"
|
||||
android:paddingStart="5dp"
|
||||
android:paddingEnd="20dp"
|
||||
android:src="@drawable/md_ic_more"
|
||||
android:visibility="gone"
|
||||
app:tint="?android:attr/textColorPrimary"
|
||||
tools:ignore="ContentDescription"
|
||||
tools:visibility="visible" />
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,2 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu />
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<dimen name="md_preference_content_inset">28dp</dimen>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<dimen name="md_dialog_max_width">446dp</dimen>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<dimen name="md_dialog_max_width">564dp</dimen>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<dimen name="md_dialog_max_width">496dp</dimen>
|
||||
|
||||
</resources>
|
||||
40
modules/material-dialogs/src/main/res/values-v11/styles.xml
Normal file
40
modules/material-dialogs/src/main/res/values-v11/styles.xml
Normal file
@@ -0,0 +1,40 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<style name="MD_Light" parent="Theme.AppCompat.Light.Dialog.Alert">
|
||||
<item name="android:windowMinWidthMajor">@dimen/abc_dialog_min_width_major</item>
|
||||
<item name="android:windowMinWidthMinor">@dimen/abc_dialog_min_width_minor</item>
|
||||
|
||||
<item name="md_divider">@color/md_divider_black</item>
|
||||
<item name="md_list_selector">@drawable/md_selector</item>
|
||||
<item name="md_btn_stacked_selector">@drawable/md_selector</item>
|
||||
<item name="md_btn_positive_selector">@drawable/md_btn_selector</item>
|
||||
<item name="md_btn_neutral_selector">@drawable/md_btn_selector</item>
|
||||
<item name="md_btn_negative_selector">@drawable/md_btn_selector</item>
|
||||
|
||||
<item name="android:actionModeBackground">@color/primary_material_dark</item>
|
||||
<item name="android:actionModeCloseDrawable">@drawable/md_nav_back</item>
|
||||
|
||||
<item name="android:windowAnimationStyle">@style/MD_WindowAnimation</item>
|
||||
<item name="android:backgroundDimEnabled">true</item>
|
||||
</style>
|
||||
|
||||
<style name="MD_Dark" parent="Theme.AppCompat.Dialog.Alert">
|
||||
<item name="android:windowMinWidthMajor">@dimen/abc_dialog_min_width_major</item>
|
||||
<item name="android:windowMinWidthMinor">@dimen/abc_dialog_min_width_minor</item>
|
||||
|
||||
<item name="md_divider">@color/md_divider_white</item>
|
||||
<item name="md_list_selector">@drawable/md_selector_dark</item>
|
||||
<item name="md_btn_stacked_selector">@drawable/md_selector_dark</item>
|
||||
<item name="md_btn_positive_selector">@drawable/md_btn_selector_dark</item>
|
||||
<item name="md_btn_neutral_selector">@drawable/md_btn_selector_dark</item>
|
||||
<item name="md_btn_negative_selector">@drawable/md_btn_selector_dark</item>
|
||||
|
||||
<item name="android:actionModeBackground">@color/primary_material_dark</item>
|
||||
<item name="android:actionModeCloseDrawable">@drawable/md_nav_back</item>
|
||||
|
||||
<item name="android:windowAnimationStyle">@style/MD_WindowAnimation</item>
|
||||
<item name="android:backgroundDimEnabled">true</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
||||
28
modules/material-dialogs/src/main/res/values-v21/styles.xml
Normal file
28
modules/material-dialogs/src/main/res/values-v21/styles.xml
Normal file
@@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<style name="MD_Light" parent="Theme.AppCompat.Light.Dialog.Alert">
|
||||
<item name="android:windowMinWidthMajor">@dimen/abc_dialog_min_width_major</item>
|
||||
<item name="android:windowMinWidthMinor">@dimen/abc_dialog_min_width_minor</item>
|
||||
|
||||
<item name="md_divider">@color/md_divider_black</item>
|
||||
<item name="md_list_selector">?android:selectableItemBackground</item>
|
||||
<item name="md_btn_stacked_selector">?android:selectableItemBackground</item>
|
||||
<item name="md_btn_positive_selector">@drawable/md_btn_selector_ripple</item>
|
||||
<item name="md_btn_neutral_selector">@drawable/md_btn_selector_ripple</item>
|
||||
<item name="md_btn_negative_selector">@drawable/md_btn_selector_ripple</item>
|
||||
</style>
|
||||
|
||||
<style name="MD_Dark" parent="Theme.AppCompat.Dialog.Alert">
|
||||
<item name="android:windowMinWidthMajor">@dimen/abc_dialog_min_width_major</item>
|
||||
<item name="android:windowMinWidthMinor">@dimen/abc_dialog_min_width_minor</item>
|
||||
|
||||
<item name="md_divider">@color/md_divider_white</item>
|
||||
<item name="md_list_selector">?android:selectableItemBackground</item>
|
||||
<item name="md_btn_stacked_selector">?android:selectableItemBackground</item>
|
||||
<item name="md_btn_positive_selector">@drawable/md_btn_selector_ripple_dark</item>
|
||||
<item name="md_btn_neutral_selector">@drawable/md_btn_selector_ripple_dark</item>
|
||||
<item name="md_btn_negative_selector">@drawable/md_btn_selector_ripple_dark</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
||||
76
modules/material-dialogs/src/main/res/values/attrs.xml
Normal file
76
modules/material-dialogs/src/main/res/values/attrs.xml
Normal file
@@ -0,0 +1,76 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<!-- These top three attributes are not accessible to library users -->
|
||||
<attr name="md_divider" format="color" />
|
||||
|
||||
<!-- Accessible global theming attributes -->
|
||||
<attr name="md_dark_theme" format="boolean" />
|
||||
<attr name="md_background_color" format="color" />
|
||||
|
||||
<attr name="md_icon" format="reference" />
|
||||
<attr name="md_icon_max_size" format="dimension" />
|
||||
<attr name="md_icon_limit_icon_to_default_size" format="boolean" />
|
||||
|
||||
<attr name="md_title_color" format="color" />
|
||||
<attr name="md_content_color" format="color" />
|
||||
<attr name="md_link_color" format="color" />
|
||||
|
||||
<attr name="md_positive_color" format="color" />
|
||||
<attr name="md_neutral_color" format="color" />
|
||||
<attr name="md_negative_color" format="color" />
|
||||
<attr name="md_widget_color" format="color" />
|
||||
|
||||
<attr name="md_item_color" format="color" />
|
||||
<attr name="md_divider_color" format="color" />
|
||||
<attr name="md_list_selector" format="reference" />
|
||||
|
||||
<attr name="md_btn_stacked_selector" format="reference" />
|
||||
<attr name="md_btn_positive_selector" format="reference" />
|
||||
<attr name="md_btn_neutral_selector" format="reference" />
|
||||
<attr name="md_btn_negative_selector" format="reference" />
|
||||
|
||||
<attr name="md_btn_ripple_color" format="color" />
|
||||
|
||||
<attr name="md_title_gravity" format="enum">
|
||||
<enum name="start" value="0" />
|
||||
<enum name="center" value="1" />
|
||||
<enum name="end" value="2" />
|
||||
</attr>
|
||||
|
||||
<attr name="md_content_gravity" format="enum">
|
||||
<enum name="start" value="0" />
|
||||
<enum name="center" value="1" />
|
||||
<enum name="end" value="2" />
|
||||
</attr>
|
||||
|
||||
<attr name="md_btnstacked_gravity" format="enum">
|
||||
<enum name="start" value="0" />
|
||||
<enum name="center" value="1" />
|
||||
<enum name="end" value="2" />
|
||||
</attr>
|
||||
|
||||
<attr name="md_items_gravity" format="enum">
|
||||
<enum name="start" value="0" />
|
||||
<enum name="center" value="1" />
|
||||
<enum name="end" value="2" />
|
||||
</attr>
|
||||
|
||||
<attr name="md_buttons_gravity" format="enum">
|
||||
<enum name="start" value="0" />
|
||||
<enum name="center" value="1" />
|
||||
<enum name="end" value="2" />
|
||||
</attr>
|
||||
|
||||
<declare-styleable name="MDRootLayout">
|
||||
<attr name="md_reduce_padding_no_title_no_buttons" format="boolean" />
|
||||
</declare-styleable>
|
||||
|
||||
<attr name="md_medium_font" format="string" />
|
||||
<attr name="md_regular_font" format="string" />
|
||||
|
||||
<declare-styleable name="Preference">
|
||||
<attr name="useStockLayout" format="boolean" />
|
||||
</declare-styleable>
|
||||
|
||||
</resources>
|
||||
22
modules/material-dialogs/src/main/res/values/colors.xml
Normal file
22
modules/material-dialogs/src/main/res/values/colors.xml
Normal file
@@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<!--<color name="content_light">#5E5E5E</color>-->
|
||||
<!--<color name="content_dark">#EDEDED</color>-->
|
||||
<!--<color name="item_light">#535353</color>-->
|
||||
<!--<color name="item_dark">#EDEDED</color>-->
|
||||
<!--<color name="button_light">#3C3C3D</color>-->
|
||||
<!--<color name="button_dark">#FFFFFF</color>-->
|
||||
|
||||
<color name="md_btn_selected">#33969696</color>
|
||||
<color name="md_btn_selected_dark">#40CBCBCB</color>
|
||||
|
||||
<color name="md_divider_black">#10000000</color>
|
||||
<color name="md_divider_white">#10FFFFFF</color>
|
||||
|
||||
<color name="md_material_blue_600">#2196F3</color>
|
||||
<color name="md_material_blue_800">#1565C0</color>
|
||||
|
||||
<color name="md_edittext_error">#DD2C00</color>
|
||||
|
||||
</resources>
|
||||
91
modules/material-dialogs/src/main/res/values/dimens.xml
Normal file
91
modules/material-dialogs/src/main/res/values/dimens.xml
Normal file
@@ -0,0 +1,91 @@
|
||||
<resources>
|
||||
<!-- See http://www.google.com/design/spec/components/dialogs.html#dialogs-specs -->
|
||||
|
||||
<!-- Notes:
|
||||
|
||||
The specs specify 16dp between the content and the buttons and imply 16dp between
|
||||
the title and the content. Also 24dp above the title and 8dp below the buttons.
|
||||
|
||||
Additionally, we interpret:
|
||||
16dp between title and content
|
||||
24dp above content if there is no title
|
||||
24dp below content if there is no button bar
|
||||
|
||||
When dialog is large enough to scroll, some padding is removed to make space and
|
||||
keep things symmetrical.
|
||||
Reduced paddings are:
|
||||
8dp above content if there is no title (0dp when scrolled)
|
||||
8dp below content if there is no button bar (0dp when scrolled)
|
||||
8dp between content and button bar
|
||||
0dp below button bar
|
||||
|
||||
For implementation:
|
||||
Content view gets 8dp vertical padding
|
||||
Title bar gets 24dp top, 8dp bottom
|
||||
Buttons get 8dp bottom
|
||||
Stacked buttons get 24dp end padding, the spec's 16 plus the spec's 8dp button padding
|
||||
|
||||
MDRootLayout takes care of margins when no title or not button bar,
|
||||
and the margin between buttons and content when not scrolling.
|
||||
-->
|
||||
|
||||
<!-- Margin around the dialog, excluding the button bar -->
|
||||
<dimen name="md_dialog_frame_margin">24dp</dimen>
|
||||
<!-- Total title margin bottom is 16, but we split this between content and title -->
|
||||
<dimen name="md_title_frame_margin_bottom">12dp</dimen>
|
||||
<dimen name="md_title_frame_margin_bottom_less">6dp</dimen>
|
||||
<!-- The desired padding when no title is visible,
|
||||
This plus md_content_padding_top should equals md_dialog_frame_margin -->
|
||||
<dimen name="md_notitle_vertical_padding">16dp</dimen>
|
||||
|
||||
<dimen name="md_notitle_vertical_padding_more">20dp</dimen>
|
||||
|
||||
<dimen name="md_content_padding_top">8dp</dimen>
|
||||
<dimen name="md_simplelistitem_padding_top">8dp</dimen>
|
||||
|
||||
<dimen name="md_button_min_width">72dp</dimen>
|
||||
<!-- Above and below buttons, 36+6+6=48 for the height of the button frame -->
|
||||
<dimen name="md_button_inset_vertical">6dp</dimen>
|
||||
<dimen name="md_button_inset_horizontal">4dp</dimen>
|
||||
<dimen name="md_button_textpadding_horizontal">1dp</dimen>
|
||||
<dimen name="md_button_padding_horizontal">8dp</dimen>
|
||||
<dimen name="md_button_padding_vertical">4dp</dimen>
|
||||
<dimen name="md_button_padding_horizontal_internalexternal">32dp</dimen>
|
||||
<!-- 16dp - 4dp (inset from background drawable) -->
|
||||
<dimen name="md_button_padding_frame_side">12dp</dimen>
|
||||
<dimen name="md_neutral_button_margin">12dp</dimen>
|
||||
|
||||
<!-- actual content padding bottom is 16dp, but we split between button bar and content -->
|
||||
<dimen name="md_content_padding_bottom">8dp</dimen>
|
||||
<dimen name="md_button_frame_vertical_padding">8dp</dimen>
|
||||
<dimen name="md_button_height">48dp</dimen>
|
||||
<dimen name="md_title_textsize">20sp</dimen>
|
||||
<dimen name="md_content_textsize">16sp</dimen>
|
||||
<dimen name="md_button_textsize">14sp</dimen>
|
||||
<dimen name="md_listitem_textsize">16sp</dimen>
|
||||
<dimen name="md_listitem_height">48dp</dimen>
|
||||
<dimen name="md_listitem_control_margin">6dp</dimen>
|
||||
<dimen name="md_icon_margin">16dp</dimen>
|
||||
<dimen name="md_icon_max_size">48dp</dimen>
|
||||
<dimen name="md_listitem_margin_left">24dp</dimen>
|
||||
<dimen name="md_action_corner_radius">2dp</dimen>
|
||||
<dimen name="md_divider_height">1dp</dimen>
|
||||
|
||||
<dimen name="md_bg_corner_radius">2dp</dimen>
|
||||
<dimen name="circular_progress_border">4dp</dimen>
|
||||
<dimen name="md_listitem_vertical_margin">12dp</dimen>
|
||||
<dimen name="md_listitem_vertical_margin_choice">8dp</dimen>
|
||||
|
||||
<dimen name="md_dialog_max_width">356dp</dimen>
|
||||
<dimen name="md_dialog_vertical_margin">52dp</dimen>
|
||||
<dimen name="md_dialog_horizontal_margin">28dp</dimen>
|
||||
|
||||
<dimen name="md_simpleitem_height">62dp</dimen>
|
||||
<dimen name="md_simplelist_icon">40dp</dimen>
|
||||
<dimen name="md_simplelist_icon_margin">16dp</dimen>
|
||||
<dimen name="md_simplelist_textsize">18sp</dimen>
|
||||
|
||||
<dimen name="md_preference_content_inset">16dp</dimen>
|
||||
<dimen name="md_colorchooser_circlesize">56dp</dimen>
|
||||
|
||||
</resources>
|
||||
13
modules/material-dialogs/src/main/res/values/ids.xml
Normal file
13
modules/material-dialogs/src/main/res/values/ids.xml
Normal file
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<item name="menu_options_item_index_0" type="id"/>
|
||||
<item name="menu_options_item_index_1" type="id"/>
|
||||
<item name="menu_options_item_index_2" type="id"/>
|
||||
<item name="menu_options_item_index_3" type="id"/>
|
||||
<item name="menu_options_item_index_4" type="id"/>
|
||||
<item name="menu_options_item_index_5" type="id"/>
|
||||
<item name="menu_options_item_index_6" type="id"/>
|
||||
<item name="menu_options_item_index_7" type="id"/>
|
||||
<item name="menu_options_item_index_8" type="id"/>
|
||||
<item name="menu_options_item_index_9" type="id"/>
|
||||
</resources>
|
||||
4
modules/material-dialogs/src/main/res/values/public.xml
Normal file
4
modules/material-dialogs/src/main/res/values/public.xml
Normal file
@@ -0,0 +1,4 @@
|
||||
<resources>
|
||||
<public name="dummy1" type="drawable"/>
|
||||
<public name="dummy2" type="drawable"/>
|
||||
</resources>
|
||||
12
modules/material-dialogs/src/main/res/values/strings.xml
Normal file
12
modules/material-dialogs/src/main/res/values/strings.xml
Normal file
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="md_back_label">Back</string>
|
||||
<string name="md_done_label">Done</string>
|
||||
<string name="md_cancel_label">Cancel</string>
|
||||
<string name="md_choose_label">Choose</string>
|
||||
<string name="md_error_label">Error</string>
|
||||
<string name="md_storage_perm_error">Your app has not been granted the READ_EXTERNAL_STORAGE permission.</string>
|
||||
<string name="md_custom_label">Custom</string>
|
||||
<string name="md_presets_label">Presets</string>
|
||||
<string name="new_folder">New Folder</string>
|
||||
</resources>
|
||||
60
modules/material-dialogs/src/main/res/values/styles.xml
Normal file
60
modules/material-dialogs/src/main/res/values/styles.xml
Normal file
@@ -0,0 +1,60 @@
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<style name="MD_Light" parent="Theme.AppCompat.Light.Dialog.Alert">
|
||||
<item name="md_divider">@color/md_divider_black</item>
|
||||
<item name="md_list_selector">@drawable/md_selector</item>
|
||||
<item name="md_btn_stacked_selector">@drawable/md_selector</item>
|
||||
<item name="md_btn_positive_selector">@drawable/md_btn_selector</item>
|
||||
<item name="md_btn_neutral_selector">@drawable/md_btn_selector</item>
|
||||
<item name="md_btn_negative_selector">@drawable/md_btn_selector</item>
|
||||
|
||||
<item name="android:windowAnimationStyle">@style/MD_WindowAnimation</item>
|
||||
<item name="android:backgroundDimEnabled">true</item>
|
||||
</style>
|
||||
|
||||
<style name="MD_Dark" parent="Theme.AppCompat.Dialog.Alert">
|
||||
<item name="md_divider">@color/md_divider_white</item>
|
||||
<item name="md_list_selector">@drawable/md_selector_dark</item>
|
||||
<item name="md_btn_stacked_selector">@drawable/md_selector_dark</item>
|
||||
<item name="md_btn_positive_selector">@drawable/md_btn_selector_dark</item>
|
||||
<item name="md_btn_neutral_selector">@drawable/md_btn_selector_dark</item>
|
||||
<item name="md_btn_negative_selector">@drawable/md_btn_selector_dark</item>
|
||||
|
||||
<item name="android:windowAnimationStyle">@style/MD_WindowAnimation</item>
|
||||
<item name="android:backgroundDimEnabled">true</item>
|
||||
</style>
|
||||
|
||||
<style name="MD_ActionButtonStacked" parent="@style/MD_ActionButton" tools:ignore="NewApi">
|
||||
<item name="android:layout_width">match_parent</item>
|
||||
<item name="android:paddingLeft">@dimen/md_button_padding_horizontal_internalexternal</item>
|
||||
<item name="android:paddingStart">@dimen/md_button_padding_horizontal_internalexternal
|
||||
</item>
|
||||
<item name="android:paddingRight">@dimen/md_button_padding_horizontal_internalexternal
|
||||
</item>
|
||||
<item name="android:paddingEnd">@dimen/md_button_padding_horizontal_internalexternal</item>
|
||||
</style>
|
||||
|
||||
<style name="MD_ActionButton">
|
||||
<item name="android:layout_width">wrap_content</item>
|
||||
<item name="android:layout_height">@dimen/md_button_height</item>
|
||||
<item name="android:layout_gravity">center_vertical</item>
|
||||
</style>
|
||||
|
||||
<style name="MD_ActionButton.Text" tools:ignore="NewApi">
|
||||
<item name="android:textSize">@dimen/md_button_textsize</item>
|
||||
<item name="android:singleLine">true</item>
|
||||
<item name="android:layout_gravity">center_vertical</item>
|
||||
<item name="android:gravity">center</item>
|
||||
<item name="android:stateListAnimator">@null</item>
|
||||
<item name="android:background">@null</item>
|
||||
<item name="android:minWidth">@dimen/md_button_min_width</item>
|
||||
<item name="android:paddingLeft">@dimen/md_button_textpadding_horizontal</item>
|
||||
<item name="android:paddingRight">@dimen/md_button_textpadding_horizontal</item>
|
||||
</style>
|
||||
|
||||
<style name="MD_WindowAnimation">
|
||||
<item name="android:windowEnterAnimation">@anim/popup_enter</item>
|
||||
<item name="android:windowExitAnimation">@anim/popup_exit</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
||||
Reference in New Issue
Block a user