Skip to content

Commit

Permalink
Replace android:tint with app:tint
Browse files Browse the repository at this point in the history
  • Loading branch information
udenr committed Dec 9, 2024
1 parent 0be22d0 commit e6d549b
Show file tree
Hide file tree
Showing 13 changed files with 1,449 additions and 1,340 deletions.
88 changes: 46 additions & 42 deletions app/src/main/res/layouts/camera/layout/camera_preview.xml
Original file line number Diff line number Diff line change
@@ -1,53 +1,57 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/layout"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">

<FrameLayout
android:id="@+id/camera_preview"
android:layout_width="match_parent"
android:layout_height="match_parent">
</FrameLayout>
android:id="@+id/camera_preview"
android:layout_width="match_parent"
android:layout_height="match_parent"></FrameLayout>

<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/button_capture"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:tint="@color/white"
android:src="@drawable/ic_camera_alt_white_48sp"

app:layout_anchorGravity="bottom|right|end"
android:layout_gravity="right|bottom" android:layout_marginLeft="@dimen/fab_margin"
android:layout_margin="@dimen/fab_margin"
android:layout_alignParentBottom="true" android:layout_alignParentEnd="true"/>
android:id="@+id/button_capture"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_alignParentBottom="true"

android:layout_gravity="right|bottom"
android:layout_margin="@dimen/fab_margin"
android:layout_marginLeft="@dimen/fab_margin"
android:src="@drawable/ic_camera_alt_white_48sp"
app:layout_anchorGravity="bottom|right|end"
app:tint="@color/white" />

<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/button_flash"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:tint="@color/white"
android:src="@drawable/ic_flash_auto_white_48sp"

app:layout_anchorGravity="bottom|right|end"
android:layout_gravity="right|top" android:layout_marginLeft="@dimen/fab_margin"
android:layout_margin="@dimen/fab_margin"
android:layout_alignParentTop="true" android:layout_alignParentEnd="true"/>
android:id="@+id/button_flash"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_alignParentEnd="true"

android:layout_gravity="right|top"
android:layout_margin="@dimen/fab_margin"
android:layout_marginLeft="@dimen/fab_margin"
android:src="@drawable/ic_flash_auto_white_48sp"
app:tint="@color/white"
app:layout_anchorGravity="bottom|right|end" />

<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/button_retake"
android:visibility="gone"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:tint="@color/white"
android:src="@drawable/ic_undo_white_48sp"

app:layout_anchorGravity="bottom|right|end"
android:layout_gravity="left|bottom" android:layout_marginLeft="@dimen/fab_margin"
android:layout_margin="@dimen/fab_margin"
android:layout_alignParentBottom="true" android:layout_alignParentStart="true"/>
android:id="@+id/button_retake"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentBottom="true"
android:layout_gravity="left|bottom"

android:layout_margin="@dimen/fab_margin"
android:layout_marginLeft="@dimen/fab_margin"
android:src="@drawable/ic_undo_white_48sp"
android:visibility="gone"
app:layout_anchorGravity="bottom|right|end"
app:tint="@color/white" />

</RelativeLayout>
Original file line number Diff line number Diff line change
@@ -1,33 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/coordinatorLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/coordinatorLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">

<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay">
</com.google.android.material.appbar.AppBarLayout>
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay"></com.google.android.material.appbar.AppBarLayout>

<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior"/>
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />

<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/fab_delete_lists"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/fab_margin"
android:tint="@color/white"
android:src="@drawable/ic_delete_white_24sp"
app:layout_anchor="@id/recyclerView"
app:layout_anchorGravity="bottom|right|end"
app:layout_behavior=".ui.fab.ScrollAwareFabBehaviorForDeleteActivities"/>
android:id="@+id/fab_delete_lists"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/fab_margin"
android:src="@drawable/ic_delete_white_24sp"
app:layout_anchor="@id/recyclerView"
app:layout_anchorGravity="bottom|right|end"
app:layout_behavior=".ui.fab.ScrollAwareFabBehaviorForDeleteActivities"
app:tint="@color/white" />

</androidx.coordinatorlayout.widget.CoordinatorLayout>
Original file line number Diff line number Diff line change
@@ -1,33 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/coordinatorLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/coordinatorLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">

<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay">
</com.google.android.material.appbar.AppBarLayout>
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay"></com.google.android.material.appbar.AppBarLayout>

<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior"/>
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />

<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/fab_delete_products"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/fab_margin"
android:tint="@color/white"
android:src="@drawable/ic_delete_white_24sp"
app:layout_anchor="@id/recyclerView"
app:layout_anchorGravity="bottom|right|end"
app:layout_behavior=".ui.fab.ScrollAwareFabBehaviorForDeleteActivities"/>
android:id="@+id/fab_delete_products"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/fab_margin"
android:src="@drawable/ic_delete_white_24sp"
app:layout_anchor="@id/recyclerView"
app:layout_anchorGravity="bottom|right|end"
app:layout_behavior=".ui.fab.ScrollAwareFabBehaviorForDeleteActivities"
app:tint="@color/white" />

</androidx.coordinatorlayout.widget.CoordinatorLayout>
110 changes: 55 additions & 55 deletions app/src/main/res/layouts/main/layout/app_bar_main.xml
Original file line number Diff line number Diff line change
@@ -1,76 +1,76 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/coordinatorLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/coordinatorLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">

<include layout="@layout/main_toolbar"/>
<include layout="@layout/main_toolbar" />

<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior"/>
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />

<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/fab_new_list"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/fab_margin"
android:tint="@color/white"
android:src="@android:drawable/ic_input_add"
app:layout_anchor="@id/recyclerView"
app:layout_anchorGravity="bottom|right|end"/>
android:id="@+id/fab_new_list"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/fab_margin"
android:src="@android:drawable/ic_input_add"
android:tint="@color/white"
app:layout_anchor="@id/recyclerView"
app:layout_anchorGravity="bottom|right|end" />

<LinearLayout
android:visibility="gone"
android:id="@+id/insert_alert"
android:orientation="horizontal"
android:layout_margin="@dimen/fab_margin"
android:paddingRight="70sp"
android:gravity="center_vertical"
app:layout_anchor="@id/fab_new_list"
app:layout_anchorGravity="bottom|left"
android:layout_width="wrap_content"
android:layout_height="50sp">
android:id="@+id/insert_alert"
android:layout_width="wrap_content"
android:layout_height="50sp"
android:layout_margin="@dimen/fab_margin"
android:gravity="center_vertical"
android:orientation="horizontal"
android:paddingRight="70sp"
android:visibility="gone"
app:layout_anchor="@id/fab_new_list"
app:layout_anchorGravity="bottom|left">

<TextView
android:text="@string/alert_message_list"
android:gravity="center_vertical"
android:textStyle="bold|italic"
android:textColor="@color/colorPrimaryDark"
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:text="@string/alert_message_list"
android:textColor="@color/colorPrimaryDark"
android:textStyle="bold|italic" />

<ImageView
android:tint="@color/colorPrimary"
android:src="@drawable/ic_keyboard_arrow_right_black_24sp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/ic_keyboard_arrow_right_black_24sp"
app:tint="@color/colorPrimary" />
</LinearLayout>

<LinearLayout
android:visibility="gone"
android:id="@+id/no_lists_layout"
android:orientation="vertical"
android:gravity="center"
android:layout_width="match_parent"
android:layout_height="match_parent">
android:id="@+id/no_lists_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical"
android:visibility="gone">

<ImageView
android:layout_gravity="center"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/icon_splash"/>
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:src="@drawable/icon_splash" />

<TextView
android:layout_gravity="center"
android:textAlignment="center"
android:text="@string/lists_empty"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:text="@string/lists_empty"
android:textAlignment="center" />
</LinearLayout>

</androidx.coordinatorlayout.widget.CoordinatorLayout>
Loading

0 comments on commit e6d549b

Please sign in to comment.