Merge "Inset the contents of AllSetActivity" into udc-qpr-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
3ce99d1d96
@@ -13,155 +13,163 @@
|
|||||||
See the License for the specific language governing permissions and
|
See the License for the specific language governing permissions and
|
||||||
limitations under the License.
|
limitations under the License.
|
||||||
-->
|
-->
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<FrameLayout
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
|
xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:theme="@style/GestureTutorialActivity"
|
android:theme="@style/GestureTutorialActivity"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:paddingTop="@dimen/gesture_tutorial_menu_padding_top"
|
android:background="?androidprv:attr/materialColorSurfaceContainer"
|
||||||
android:paddingBottom="@dimen/gesture_tutorial_menu_padding_bottom"
|
android:fitsSystemWindows="true">
|
||||||
android:paddingHorizontal="@dimen/gesture_tutorial_menu_padding_horizontal"
|
|
||||||
android:background="?androidprv:attr/materialColorSurfaceContainer">
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/gesture_tutorial_menu_home_button"
|
android:layout_width="match_parent"
|
||||||
android:layout_width="0dp"
|
android:layout_height="match_parent"
|
||||||
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
android:paddingTop="@dimen/gesture_tutorial_menu_padding_top"
|
||||||
android:layout_marginEnd="@dimen/gesture_tutorial_menu_button_spacing"
|
android:paddingBottom="@dimen/gesture_tutorial_menu_padding_bottom"
|
||||||
android:layout_marginBottom="24dp"
|
android:paddingHorizontal="@dimen/gesture_tutorial_menu_padding_horizontal"
|
||||||
android:background="@drawable/gesture_tutorial_menu_home_button_background"
|
android:clipToPadding="false">
|
||||||
android:clipToOutline="true"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
app:layout_constraintBottom_toTopOf="@id/guideline"
|
android:id="@+id/gesture_tutorial_menu_home_button"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
android:layout_width="0dp"
|
||||||
app:layout_constraintEnd_toStartOf="@id/gesture_tutorial_menu_back_button">
|
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
||||||
|
android:layout_marginEnd="@dimen/gesture_tutorial_menu_button_spacing"
|
||||||
<ImageView
|
android:layout_marginBottom="24dp"
|
||||||
android:layout_width="wrap_content"
|
android:background="@drawable/gesture_tutorial_menu_home_button_background"
|
||||||
android:layout_height="wrap_content"
|
android:clipToOutline="true"
|
||||||
android:src="@drawable/gesture_tutorial_home_step_shape"
|
|
||||||
android:scaleType="fitXY"
|
|
||||||
android:adjustViewBounds="true"
|
|
||||||
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/TextAppearance.GestureTutorial.MenuButton.Home"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_home_button_text"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/home_gesture_tutorial_title"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toTopOf="@id/guideline"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toStartOf="@id/gesture_tutorial_menu_back_button">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:src="@drawable/gesture_tutorial_home_step_shape"
|
||||||
|
android:scaleType="fitXY"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextAppearance.GestureTutorial.MenuButton.Home"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_home_button_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/home_gesture_tutorial_title"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/gesture_tutorial_menu_back_button"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
||||||
|
android:layout_marginEnd="@dimen/gesture_tutorial_menu_button_spacing"
|
||||||
|
android:layout_marginBottom="24dp"
|
||||||
|
android:background="@drawable/gesture_tutorial_menu_back_button_background"
|
||||||
|
android:clipToOutline="true"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toTopOf="@id/guideline"
|
||||||
|
app:layout_constraintStart_toEndOf="@id/gesture_tutorial_menu_home_button"
|
||||||
|
app:layout_constraintEnd_toStartOf="@id/gesture_tutorial_menu_overview_button">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:src="@drawable/gesture_tutorial_back_step_shape"
|
||||||
|
android:layout_marginBottom="@dimen/gesture_tutorial_menu_back_shape_bottom_margin"
|
||||||
|
android:scaleType="fitXY"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextAppearance.GestureTutorial.MenuButton.Back"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_back_button_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/back_gesture_tutorial_title"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/gesture_tutorial_menu_overview_button"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
||||||
|
android:layout_marginBottom="24dp"
|
||||||
|
android:background="@drawable/gesture_tutorial_menu_overview_button_background"
|
||||||
|
android:clipToOutline="true"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toTopOf="@id/guideline"
|
||||||
|
app:layout_constraintStart_toEndOf="@id/gesture_tutorial_menu_back_button"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:src="@drawable/gesture_tutorial_overview_step_shape"
|
||||||
|
android:scaleType="fitXY"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextAppearance.GestureTutorial.MenuButton.Overview"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_overview_button_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/overview_gesture_tutorial_title"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.Guideline
|
||||||
|
android:id="@+id/guideline"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
|
||||||
|
app:layout_constraintGuide_end="@dimen/gesture_tutorial_menu_done_button_spacing"/>
|
||||||
|
|
||||||
|
<Button
|
||||||
|
style="@style/TextAppearance.GestureTutorial.ButtonLabel"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_done_button"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_marginVertical="16dp"
|
||||||
|
android:text="@string/gesture_tutorial_action_button_label"
|
||||||
|
android:background="@drawable/gesture_tutorial_action_button_background"
|
||||||
|
android:backgroundTint="?androidprv:attr/materialColorPrimary"
|
||||||
|
android:stateListAnimator="@null"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/guideline"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
</FrameLayout>
|
||||||
android:id="@+id/gesture_tutorial_menu_back_button"
|
|
||||||
android:layout_width="0dp"
|
|
||||||
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
|
||||||
android:layout_marginEnd="@dimen/gesture_tutorial_menu_button_spacing"
|
|
||||||
android:layout_marginBottom="24dp"
|
|
||||||
android:background="@drawable/gesture_tutorial_menu_back_button_background"
|
|
||||||
android:clipToOutline="true"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
app:layout_constraintBottom_toTopOf="@id/guideline"
|
|
||||||
app:layout_constraintStart_toEndOf="@id/gesture_tutorial_menu_home_button"
|
|
||||||
app:layout_constraintEnd_toStartOf="@id/gesture_tutorial_menu_overview_button">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:src="@drawable/gesture_tutorial_back_step_shape"
|
|
||||||
android:layout_marginBottom="@dimen/gesture_tutorial_menu_back_shape_bottom_margin"
|
|
||||||
android:scaleType="fitXY"
|
|
||||||
android:adjustViewBounds="true"
|
|
||||||
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/TextAppearance.GestureTutorial.MenuButton.Back"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_back_button_text"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/back_gesture_tutorial_title"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:id="@+id/gesture_tutorial_menu_overview_button"
|
|
||||||
android:layout_width="0dp"
|
|
||||||
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
|
||||||
android:layout_marginBottom="24dp"
|
|
||||||
android:background="@drawable/gesture_tutorial_menu_overview_button_background"
|
|
||||||
android:clipToOutline="true"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
app:layout_constraintBottom_toTopOf="@id/guideline"
|
|
||||||
app:layout_constraintStart_toEndOf="@id/gesture_tutorial_menu_back_button"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:src="@drawable/gesture_tutorial_overview_step_shape"
|
|
||||||
android:scaleType="fitXY"
|
|
||||||
android:adjustViewBounds="true"
|
|
||||||
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/TextAppearance.GestureTutorial.MenuButton.Overview"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_overview_button_text"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/overview_gesture_tutorial_title"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.Guideline
|
|
||||||
android:id="@+id/guideline"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal"
|
|
||||||
|
|
||||||
app:layout_constraintGuide_end="@dimen/gesture_tutorial_menu_done_button_spacing"/>
|
|
||||||
|
|
||||||
<Button
|
|
||||||
style="@style/TextAppearance.GestureTutorial.ButtonLabel"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_done_button"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="40dp"
|
|
||||||
android:layout_marginVertical="16dp"
|
|
||||||
android:text="@string/gesture_tutorial_action_button_label"
|
|
||||||
android:background="@drawable/gesture_tutorial_action_button_background"
|
|
||||||
android:backgroundTint="?androidprv:attr/materialColorPrimary"
|
|
||||||
android:stateListAnimator="@null"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toBottomOf="@id/guideline"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
@@ -41,6 +41,7 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:fillViewport="true"
|
android:fillViewport="true"
|
||||||
|
android:fitsSystemWindows="true"
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
@@ -95,7 +96,6 @@
|
|||||||
style="@style/TextAppearance.GestureTutorial.Feedback.Subtitle"
|
style="@style/TextAppearance.GestureTutorial.Feedback.Subtitle"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginBottom="24dp"
|
|
||||||
android:text="@string/allset_hint"
|
android:text="@string/allset_hint"
|
||||||
android:textSize="@dimen/allset_page_swipe_up_text_size"
|
android:textSize="@dimen/allset_page_swipe_up_text_size"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
|
|||||||
@@ -13,154 +13,161 @@
|
|||||||
See the License for the specific language governing permissions and
|
See the License for the specific language governing permissions and
|
||||||
limitations under the License.
|
limitations under the License.
|
||||||
-->
|
-->
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<FrameLayout
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
|
xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:theme="@style/GestureTutorialActivity"
|
android:theme="@style/GestureTutorialActivity"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:paddingTop="@dimen/gesture_tutorial_menu_padding_top"
|
|
||||||
android:paddingBottom="@dimen/gesture_tutorial_menu_padding_bottom"
|
|
||||||
android:paddingHorizontal="@dimen/gesture_tutorial_menu_padding_horizontal"
|
|
||||||
android:background="?androidprv:attr/materialColorSurfaceContainer"
|
android:background="?androidprv:attr/materialColorSurfaceContainer"
|
||||||
android:clipToPadding="false">
|
android:fitsSystemWindows="true">
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/gesture_tutorial_menu_home_button"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
android:layout_height="match_parent"
|
||||||
android:background="@drawable/gesture_tutorial_menu_home_button_background"
|
android:paddingTop="@dimen/gesture_tutorial_menu_padding_top"
|
||||||
android:clipToOutline="true"
|
android:paddingBottom="@dimen/gesture_tutorial_menu_padding_bottom"
|
||||||
app:layout_constraintVertical_chainStyle="packed"
|
android:paddingHorizontal="@dimen/gesture_tutorial_menu_padding_horizontal"
|
||||||
|
android:clipToPadding="false">
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
app:layout_constraintBottom_toTopOf="@id/gesture_tutorial_menu_back_button"
|
android:id="@+id/gesture_tutorial_menu_home_button"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
android:layout_width="match_parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent">
|
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
||||||
|
android:background="@drawable/gesture_tutorial_menu_home_button_background"
|
||||||
<ImageView
|
android:clipToOutline="true"
|
||||||
android:layout_width="wrap_content"
|
app:layout_constraintVertical_chainStyle="packed"
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:src="@drawable/gesture_tutorial_home_step_shape"
|
|
||||||
android:scaleType="fitXY"
|
|
||||||
android:adjustViewBounds="true"
|
|
||||||
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/TextAppearance.GestureTutorial.MenuButton.Home"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_home_button_text"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/home_gesture_tutorial_title"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toTopOf="@id/gesture_tutorial_menu_back_button"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:src="@drawable/gesture_tutorial_home_step_shape"
|
||||||
|
android:scaleType="fitXY"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextAppearance.GestureTutorial.MenuButton.Home"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_home_button_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/home_gesture_tutorial_title"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/gesture_tutorial_menu_back_button"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
||||||
|
android:layout_marginTop="@dimen/gesture_tutorial_menu_button_spacing"
|
||||||
|
android:background="@drawable/gesture_tutorial_menu_back_button_background"
|
||||||
|
android:clipToOutline="true"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/gesture_tutorial_menu_home_button"
|
||||||
|
app:layout_constraintBottom_toTopOf="@id/gesture_tutorial_menu_overview_button"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:src="@drawable/gesture_tutorial_back_step_shape"
|
||||||
|
android:scaleType="fitXY"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextAppearance.GestureTutorial.MenuButton.Back"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_back_button_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/back_gesture_tutorial_title"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/gesture_tutorial_menu_overview_button"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
||||||
|
android:layout_marginTop="@dimen/gesture_tutorial_menu_button_spacing"
|
||||||
|
android:background="@drawable/gesture_tutorial_menu_overview_button_background"
|
||||||
|
android:clipToOutline="true"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/gesture_tutorial_menu_back_button"
|
||||||
|
app:layout_constraintBottom_toTopOf="@id/guideline"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:src="@drawable/gesture_tutorial_overview_step_shape"
|
||||||
|
android:scaleType="fitXY"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextAppearance.GestureTutorial.MenuButton.Overview"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_overview_button_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/overview_gesture_tutorial_title"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.Guideline
|
||||||
|
android:id="@+id/guideline"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
|
||||||
|
app:layout_constraintGuide_end="@dimen/gesture_tutorial_menu_done_button_spacing"/>
|
||||||
|
|
||||||
|
<Button
|
||||||
|
style="@style/TextAppearance.GestureTutorial.ButtonLabel"
|
||||||
|
android:id="@+id/gesture_tutorial_menu_done_button"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_marginVertical="16dp"
|
||||||
|
android:text="@string/gesture_tutorial_action_button_label"
|
||||||
|
android:background="@drawable/gesture_tutorial_action_button_background"
|
||||||
|
android:backgroundTint="?androidprv:attr/materialColorPrimary"
|
||||||
|
android:stateListAnimator="@null"
|
||||||
|
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/guideline"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
app:layout_constraintEnd_toEndOf="parent"/>
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
</FrameLayout>
|
||||||
android:id="@+id/gesture_tutorial_menu_back_button"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
|
||||||
android:layout_marginTop="@dimen/gesture_tutorial_menu_button_spacing"
|
|
||||||
android:background="@drawable/gesture_tutorial_menu_back_button_background"
|
|
||||||
android:clipToOutline="true"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toBottomOf="@id/gesture_tutorial_menu_home_button"
|
|
||||||
app:layout_constraintBottom_toTopOf="@id/gesture_tutorial_menu_overview_button"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:src="@drawable/gesture_tutorial_back_step_shape"
|
|
||||||
android:scaleType="fitXY"
|
|
||||||
android:adjustViewBounds="true"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/TextAppearance.GestureTutorial.MenuButton.Back"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_back_button_text"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/back_gesture_tutorial_title"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:id="@+id/gesture_tutorial_menu_overview_button"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="@dimen/gesture_tutorial_menu_button_height"
|
|
||||||
android:layout_marginTop="@dimen/gesture_tutorial_menu_button_spacing"
|
|
||||||
android:background="@drawable/gesture_tutorial_menu_overview_button_background"
|
|
||||||
android:clipToOutline="true"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toBottomOf="@id/gesture_tutorial_menu_back_button"
|
|
||||||
app:layout_constraintBottom_toTopOf="@id/guideline"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:src="@drawable/gesture_tutorial_overview_step_shape"
|
|
||||||
android:scaleType="fitXY"
|
|
||||||
android:adjustViewBounds="true"
|
|
||||||
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/TextAppearance.GestureTutorial.MenuButton.Overview"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_overview_button_text"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/overview_gesture_tutorial_title"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.Guideline
|
|
||||||
android:id="@+id/guideline"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal"
|
|
||||||
|
|
||||||
app:layout_constraintGuide_end="@dimen/gesture_tutorial_menu_done_button_spacing"/>
|
|
||||||
|
|
||||||
<Button
|
|
||||||
style="@style/TextAppearance.GestureTutorial.ButtonLabel"
|
|
||||||
android:id="@+id/gesture_tutorial_menu_done_button"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="40dp"
|
|
||||||
android:layout_marginVertical="16dp"
|
|
||||||
android:text="@string/gesture_tutorial_action_button_label"
|
|
||||||
android:background="@drawable/gesture_tutorial_action_button_background"
|
|
||||||
android:backgroundTint="?androidprv:attr/materialColorPrimary"
|
|
||||||
android:stateListAnimator="@null"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toBottomOf="@id/guideline"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
@@ -19,7 +19,6 @@ import static com.android.quickstep.interaction.GestureSandboxActivity.KEY_GESTU
|
|||||||
import static com.android.quickstep.interaction.GestureSandboxActivity.KEY_TUTORIAL_TYPE;
|
import static com.android.quickstep.interaction.GestureSandboxActivity.KEY_TUTORIAL_TYPE;
|
||||||
import static com.android.quickstep.interaction.GestureSandboxActivity.KEY_USE_TUTORIAL_MENU;
|
import static com.android.quickstep.interaction.GestureSandboxActivity.KEY_USE_TUTORIAL_MENU;
|
||||||
|
|
||||||
import android.graphics.Rect;
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
@@ -28,33 +27,17 @@ import android.view.ViewGroup;
|
|||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
import androidx.annotation.Nullable;
|
import androidx.annotation.Nullable;
|
||||||
|
|
||||||
import com.android.launcher3.InvariantDeviceProfile;
|
|
||||||
import com.android.launcher3.R;
|
import com.android.launcher3.R;
|
||||||
|
|
||||||
/** Displays the gesture nav tutorial menu. */
|
/** Displays the gesture nav tutorial menu. */
|
||||||
public final class MenuFragment extends GestureSandboxFragment {
|
public final class MenuFragment extends GestureSandboxFragment {
|
||||||
|
|
||||||
@NonNull private Rect mInsets = new Rect();
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onCreate(@Nullable Bundle savedInstanceState) {
|
|
||||||
super.onCreate(savedInstanceState);
|
|
||||||
mInsets = InvariantDeviceProfile.INSTANCE.get(getContext())
|
|
||||||
.getDeviceProfile(getContext()).getInsets();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container,
|
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container,
|
||||||
@Nullable Bundle savedInstanceState) {
|
@Nullable Bundle savedInstanceState) {
|
||||||
View root = inflater.inflate(
|
final View root = inflater.inflate(
|
||||||
R.layout.gesture_tutorial_step_menu, container, false);
|
R.layout.gesture_tutorial_step_menu, container, false);
|
||||||
|
|
||||||
root.setPadding(
|
|
||||||
root.getPaddingLeft() + mInsets.left,
|
|
||||||
root.getPaddingTop() + mInsets.top,
|
|
||||||
root.getPaddingRight() + mInsets.right,
|
|
||||||
root.getPaddingBottom() + mInsets.bottom);
|
|
||||||
|
|
||||||
root.findViewById(R.id.gesture_tutorial_menu_home_button).setOnClickListener(
|
root.findViewById(R.id.gesture_tutorial_menu_home_button).setOnClickListener(
|
||||||
v -> launchTutorialStep(TutorialController.TutorialType.HOME_NAVIGATION));
|
v -> launchTutorialStep(TutorialController.TutorialType.HOME_NAVIGATION));
|
||||||
root.findViewById(R.id.gesture_tutorial_menu_back_button).setOnClickListener(
|
root.findViewById(R.id.gesture_tutorial_menu_back_button).setOnClickListener(
|
||||||
|
|||||||
Reference in New Issue
Block a user