Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix resource naming #6

Merged
merged 25 commits into from
Jan 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
a144d76
New build.yaml action
duartebarbosadev Jan 20, 2025
4746082
New build.yaml action
duartebarbosadev Jan 20, 2025
b5c62f5
New build.yaml action
duartebarbosadev Jan 22, 2025
80ab639
New build.yaml action
duartebarbosadev Jan 22, 2025
e580eb0
New build.yaml action
duartebarbosadev Jan 22, 2025
d6c561f
New build.yaml action
duartebarbosadev Jan 22, 2025
eec3035
Fixed buildLogic wrong project name
duartebarbosadev Jan 22, 2025
4530f03
Concurrency and gradle properties
duartebarbosadev Jan 22, 2025
fdade7b
Concurrency and gradle properties
duartebarbosadev Jan 22, 2025
34db544
Updated gradlew permissions
duartebarbosadev Jan 22, 2025
2424f90
Merge branch 'main' of https://github.com/DuarteBarbosaPT/Scrolless i…
duartebarbosadev Jan 23, 2025
4085b3a
Merge branch 'main' into 3-github-actions---build-project
duartebarbosadev Jan 23, 2025
9d943c6
Updated gradlew permissions
duartebarbosadev Jan 23, 2025
3601d97
Merge remote-tracking branch 'origin/3-github-actions---build-project…
duartebarbosadev Jan 23, 2025
d082ddd
Updated gradlew permissions
duartebarbosadev Jan 23, 2025
e9864fb
Changed google-services but this should be temporary
duartebarbosadev Jan 23, 2025
ce40182
Changed google-services
duartebarbosadev Jan 23, 2025
95c84f7
Changed google-services
duartebarbosadev Jan 23, 2025
98110f0
Fixed firebase which was trying to upload mapping
duartebarbosadev Jan 24, 2025
ed2ec23
Removed libs for now
duartebarbosadev Jan 24, 2025
360428c
Fixed resource naming
duartebarbosadev Jan 25, 2025
44dde6e
Fixed resource naming
duartebarbosadev Jan 25, 2025
7cb6159
Fixed resource naming
duartebarbosadev Jan 25, 2025
9f11d8b
Fixed resource naming
duartebarbosadev Jan 26, 2025
cbe4c73
Merge branch 'main' into fix-resource-naming
duartebarbosadev Jan 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
* All rights reserved.
*/

import com.android.build.api.dsl.BuildType
import com.scrolless.app.ScrollessBuildType

plugins {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ import android.content.Context
import android.view.LayoutInflater
import android.view.Window
import com.google.android.material.dialog.MaterialAlertDialogBuilder
import com.scrolless.libraries.components.databinding.DialogInternetCheckBinding
import com.scrolless.libraries.components.databinding.LibrariesComponentsDialogInternetCheckBinding

object DialogHelper {
fun showInternetCheckDialog(context: Context, handler: () -> Unit) {
val dialogBuilder = MaterialAlertDialogBuilder(context)
val layoutInflater = LayoutInflater.from(context)
val binding = DialogInternetCheckBinding.inflate(layoutInflater)
val binding = LibrariesComponentsDialogInternetCheckBinding.inflate(layoutInflater)
dialogBuilder.setView(binding.root)

val alertDialog = dialogBuilder.create().apply {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ import android.graphics.Color
import android.graphics.drawable.ColorDrawable
import android.view.Window
import android.view.WindowManager
import com.scrolless.libraries.components.databinding.DialogProgressBinding
import com.scrolless.libraries.components.databinding.LibrariesComponentsDialogProgressBinding

class ProgressDialog(context: Context) : Dialog(context) {
init {
val binding = DialogProgressBinding.inflate(layoutInflater)
val binding = LibrariesComponentsDialogProgressBinding.inflate(layoutInflater)
requestWindowFeature(Window.FEATURE_NO_TITLE)
window?.setBackgroundDrawable(ColorDrawable(Color.TRANSPARENT))
window?.setLayout(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class ThemeSwitch @JvmOverloads constructor(
) : SwitchMaterial(context, attrs) {

init {
thumbDrawable = AppCompatResources.getDrawable(context, R.drawable.selector_dark_light)
trackDrawable = AppCompatResources.getDrawable(context, R.drawable.selector_bg_dark_light)
thumbDrawable = AppCompatResources.getDrawable(context, R.drawable.libraries_components_selector_dark_light)
trackDrawable = AppCompatResources.getDrawable(context, R.drawable.libraries_components_selector_bg_dark_light)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ import androidx.paging.LoadState
import androidx.paging.LoadStateAdapter
import androidx.paging.PagingDataAdapter
import androidx.recyclerview.widget.RecyclerView
import com.scrolless.libraries.components.databinding.RowPagingLoadStateBinding
import com.scrolless.libraries.components.databinding.LibrariesComponentsRowPagingLoadStateBinding

class PagingLoadStateAdapter<T : Any, VH : RecyclerView.ViewHolder>(
private val adapter: PagingDataAdapter<T, VH>
) : LoadStateAdapter<PagingLoadStateAdapter.PagingLoadStateViewHolder>() {

class PagingLoadStateViewHolder(
private val binding: RowPagingLoadStateBinding,
private val binding: LibrariesComponentsRowPagingLoadStateBinding,
private val retryCallback: () -> Unit
) : RecyclerView.ViewHolder(binding.root) {
init {
Expand All @@ -43,7 +43,7 @@ class PagingLoadStateAdapter<T : Any, VH : RecyclerView.ViewHolder>(
loadState: LoadState
): PagingLoadStateViewHolder =
PagingLoadStateViewHolder(
RowPagingLoadStateBinding.inflate(
LibrariesComponentsRowPagingLoadStateBinding.inflate(
LayoutInflater.from(parent.context),
parent,
false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ abstract class BasicSwipeAdapter<T : Any, Binding : ViewBinding> :
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): BasicViewHolder<Binding> {
val vh = super.onCreateViewHolder(parent, viewType)
val mainView = LayoutInflater.from(parent.context)
.inflate(R.layout.row_swipe_recycler, parent, false)
.inflate(R.layout.libraries_components_row_swipe_recycler, parent, false)

val swipeContent = mainView.findViewById<FrameLayout>(R.id.swipeContent)
swipeContent.addView(vh.itemView)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ open class SwipeMenuView @JvmOverloads constructor(
parent.gravity = Gravity.CENTER
parent.orientation = item.orientation
parent.layoutParams = params
val padding = resources.getDimensionPixelSize(R.dimen.swipe_dimen)
val padding = resources.getDimensionPixelSize(R.dimen.libraries_components_swipe_dimen)
parent.setPadding(padding, 0, padding, 0)
parent.setOnClickListener {
mItemClickListener?.invoke(item, position)
Expand Down
9 changes: 0 additions & 9 deletions libraries/components/src/main/res/color/rp_week_btn_color.xml

This file was deleted.

9 changes: 0 additions & 9 deletions libraries/components/src/main/res/color/rp_week_btn_text.xml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2024, Scrolless
All rights reserved.
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/libraries_components_ic_sun" android:state_checked="false" />
<item android:drawable="@drawable/libraries_components_ic_moon" android:state_checked="true" />
</selector>

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_dialog_radius"
android:background="@drawable/libraries_components_bg_dialog_radius"
android:orientation="vertical"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
Expand All @@ -25,7 +25,7 @@
android:layout_height="100dp"
android:layout_gravity="center"
android:layout_marginTop="16dp"
app:srcCompat="@drawable/ic_baseline_wifi_off_24" />
app:srcCompat="@drawable/libraries_components_ic_baseline_wifi_off_24" />

<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
Expand All @@ -34,7 +34,7 @@
android:layout_marginTop="32dp"
android:layout_marginEnd="16dp"
android:gravity="center"
android:text="@string/text_check_internet_dialog_message"
android:text="@string/libraries_components_text_check_internet_dialog_message"
android:textAlignment="center"
android:textSize="16sp"
app:layout_constraintEnd_toEndOf="parent"
Expand All @@ -47,7 +47,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="24dp"
android:text="@string/btn_check_internet_close"
android:text="@string/libraries_components_btn_check_internet_close"
android:textAllCaps="false"
android:textSize="16sp" />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
android:layout_height="50dp"
android:layout_centerInParent="true"
android:indeterminate="true"
android:indeterminateDrawable="@drawable/pb_progress"
android:indeterminateDrawable="@drawable/libraries_components_pb_progress"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="@string/internet_connection_error" />
tools:text="@string/libraries_components_internet_connection_error" />

<androidx.core.widget.ContentLoadingProgressBar
android:id="@+id/pbLoading"
Expand All @@ -37,7 +37,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:backgroundTint="@android:color/holo_red_dark"
android:text="@string/retry"
android:text="@string/libraries_components_retry"
android:textAllCaps="false"
android:textColor="@android:color/white"
app:layout_constraintBottom_toBottomOf="parent"
Expand Down
8 changes: 0 additions & 8 deletions libraries/components/src/main/res/values/arrays.xml

This file was deleted.

4 changes: 2 additions & 2 deletions libraries/components/src/main/res/values/attrs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
Copyright (C) 2024, Scrolless
All rights reserved.
-->
<resources>
<resources xmlns:tools="http://schemas.android.com/tools">

<declare-styleable name="SwipeMenuLayout">
<declare-styleable name="SwipeMenuLayout" tools:ignore="ResourceName">
<attr name="contentView" format="reference" />
<attr name="rightMenuEnable" format="boolean" />
<attr name="leftMenuEnable" format="boolean" />
Expand Down
6 changes: 3 additions & 3 deletions libraries/components/src/main/res/values/dimens.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
All rights reserved.
-->
<resources>
<dimen name="swipe_dimen">6dp</dimen>
<dimen name="sheetsTextSizeSubheading">16sp</dimen>
<dimen name="sheetsTextSizeTitle">20sp</dimen>
<dimen name="libraries_components_swipe_dimen">6dp</dimen>
<dimen name="libraries_components_sheetsTextSizeSubheading">16sp</dimen>
<dimen name="libraries_components_sheetsTextSizeTitle">20sp</dimen>
</resources>
8 changes: 4 additions & 4 deletions libraries/components/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
All rights reserved.
-->
<resources>
<string name="retry">Retry</string>
<string name="internet_connection_error">Check your connection!</string>
<string name="text_check_internet_dialog_message">Check your internet connection!</string>
<string name="btn_check_internet_close">Close</string>
<string name="libraries_components_retry">Retry</string>
<string name="libraries_components_internet_connection_error">Check your connection!</string>
<string name="libraries_components_text_check_internet_dialog_message">Check your internet connection!</string>
<string name="libraries_components_btn_check_internet_close">Close</string>
</resources>
Original file line number Diff line number Diff line change
Expand Up @@ -20,45 +20,45 @@ enum class AnimationType {
fun getAnimation(type: AnimationType): List<Int> {
when (type) {
DEFAULT -> return listOf(
R.anim.slide_in_right,
R.anim.slide_out_left,
R.anim.slide_in_left,
R.anim.slide_out_right,
R.anim.libraries_framework_slide_in_right,
R.anim.libraries_framework_slide_out_left,
R.anim.libraries_framework_slide_in_left,
R.anim.libraries_framework_slide_out_right,
)

ENTER_FROM_LEFT -> return listOf(
R.anim.anim_fragment_in_from_pop,
R.anim.anim_fragment_out_from_pop,
R.anim.anim_fragment_in,
R.anim.anim_fragment_out,
R.anim.libraries_framework_anim_fragment_in_from_pop,
R.anim.libraries_framework_anim_fragment_out_from_pop,
R.anim.libraries_framework_anim_fragment_in,
R.anim.libraries_framework_anim_fragment_out,
)

ENTER_FROM_LEFT_WITH_SCALE -> return listOf(
R.anim.anim_scale_fragment_in_from_pop,
R.anim.anim_scale_fragment_out_from_pop,
R.anim.anim_scale_fragment_in,
R.anim.anim_scale_fragment_out,
R.anim.libraries_framework_anim_scale_fragment_in_from_pop,
R.anim.libraries_framework_anim_scale_fragment_out_from_pop,
R.anim.libraries_framework_anim_scale_fragment_in,
R.anim.libraries_framework_anim_scale_fragment_out,
)

ENTER_FROM_RIGHT -> return listOf(
R.anim.anim_fragment_in,
R.anim.anim_fragment_out,
R.anim.anim_fragment_in_from_pop,
R.anim.anim_fragment_out_from_pop,
R.anim.libraries_framework_anim_fragment_in,
R.anim.libraries_framework_anim_fragment_out,
R.anim.libraries_framework_anim_fragment_in_from_pop,
R.anim.libraries_framework_anim_fragment_out_from_pop,
)

ENTER_FROM_RIGHT_WITH_SCALE -> return listOf(
R.anim.anim_scale_fragment_in,
R.anim.anim_scale_fragment_out,
R.anim.anim_scale_fragment_in_from_pop,
R.anim.anim_scale_fragment_out_from_pop,
R.anim.libraries_framework_anim_scale_fragment_in,
R.anim.libraries_framework_anim_scale_fragment_out,
R.anim.libraries_framework_anim_scale_fragment_in_from_pop,
R.anim.libraries_framework_anim_scale_fragment_out_from_pop,
)

ENTER_FROM_BOTTOM -> return listOf(
R.anim.anim_vertical_fragment_in_long,
R.anim.anim_vertical_fragment_out_long,
R.anim.anim_vertical_fragment_in_from_pop_long,
R.anim.anim_vertical_fragment_out_from_pop_long,
R.anim.libraries_framework_anim_vertical_fragment_in_long,
R.anim.libraries_framework_anim_vertical_fragment_out_long,
R.anim.libraries_framework_anim_vertical_fragment_in_from_pop_long,
R.anim.libraries_framework_anim_vertical_fragment_out_from_pop_long,
)

NO_ANIM -> return listOf()
Expand Down
14 changes: 0 additions & 14 deletions libraries/framework/src/main/res/drawable/email_outline.xml

This file was deleted.

14 changes: 0 additions & 14 deletions libraries/framework/src/main/res/drawable/message_processing.xml

This file was deleted.

12 changes: 6 additions & 6 deletions libraries/framework/src/main/res/values/ids.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
Copyright (C) 2024, Scrolless
All rights reserved.
-->
<resources>
<item type="id" name="nav_container" />
<resources xmlns:tools="http://schemas.android.com/tools">
<item type="id" name="nav_container" tools:ignore="ResourceName" />

<item name="view_add_insets_padding_top_tag" type="id" />
<item name="view_add_insets_padding_bottom_tag" type="id" />
<item name="view_add_insets_padding_left_tag" type="id" />
<item name="view_add_insets_padding_right_tag" type="id" />
<item name="view_add_insets_padding_top_tag" type="id" tools:ignore="ResourceName" />
<item name="view_add_insets_padding_bottom_tag" type="id" tools:ignore="ResourceName" />
<item name="view_add_insets_padding_left_tag" type="id" tools:ignore="ResourceName" />
<item name="view_add_insets_padding_right_tag" type="id" tools:ignore="ResourceName" />

</resources>
Loading