Skip to content
This repository has been archived by the owner on Aug 30, 2024. It is now read-only.

Commit

Permalink
update gradle, unused unnecessary material components cuz its theme i…
Browse files Browse the repository at this point in the history
…s Material already
  • Loading branch information
KenMizz committed Feb 10, 2021
1 parent d1d58b0 commit 783a6c6
Show file tree
Hide file tree
Showing 5 changed files with 54 additions and 53 deletions.
2 changes: 1 addition & 1 deletion app/src/main/res/layout/about.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
app:layout_constraintVertical_bias="0.024"
app:srcCompat="@drawable/app_icon_around" />

<com.google.android.material.textview.MaterialTextView
<TextView
android:id="@+id/materialTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
android:layout_height="match_parent"
tools:context=".MainActivity">

<com.google.android.material.textview.MaterialTextView
<TextView
android:id="@+id/emptyView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand Down
93 changes: 47 additions & 46 deletions app/src/main/res/layout/activity_sentence_attribute_dialog.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,9 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/grey"
tools:context=".SentenceAttributeDialog">

<com.google.android.material.button.MaterialButton
android:id="@+id/SentenceAttributeConfirmButton"
style="@style/Widget.MaterialComponents.Button.TextButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/confirmButton"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.945"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.975" />

<Space
android:id="@+id/space3"
android:layout_width="20dp"
Expand All @@ -39,51 +27,76 @@
android:id="@+id/space5"
android:layout_width="306dp"
android:layout_height="101dp"
android:layout_marginTop="68dp"
android:layout_marginTop="100dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.493"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/SentenceAttributeSlider" />

<Button
android:id="@+id/SentenceAttributeConfirmButton"
style="@style/Widget.MaterialComponents.Button.TextButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/confirmButton"
android:textColor="@color/white"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.945"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.975" />

<Button
android:id="@+id/SentenceAttributeColorPicker"
style="?attr/materialButtonOutlinedStyle"
android:layout_width="57dp"
android:layout_height="67dp"
android:layout_marginTop="12dp"
android:layout_marginEnd="108dp"
android:backgroundTint="@color/white"
app:layout_constraintEnd_toEndOf="@+id/SentenceAttributeSlider"
app:layout_constraintTop_toBottomOf="@+id/SentenceAttributeSlider" />

<com.google.android.material.slider.Slider
android:id="@+id/SentenceAttributeSlider"
android:layout_width="189dp"
android:layout_height="49dp"
android:layout_marginTop="48dp"
android:layout_marginTop="76dp"
android:value="10.0"
android:valueFrom="10.0"
android:valueTo="100.0"
app:labelBehavior="floating"
app:layout_constraintEnd_toEndOf="@+id/SentenceAttributeTextView"
app:layout_constraintHorizontal_bias="0.502"
app:layout_constraintHorizontal_bias="0.451"
app:layout_constraintStart_toStartOf="@+id/SentenceAttributeTextView"
app:layout_constraintTop_toBottomOf="@+id/space3"
app:thumbColor="@color/white"
app:trackColor="@color/white" />

<com.google.android.material.button.MaterialButton
android:id="@+id/SentenceAttributeColorPicker"
style="?attr/materialButtonOutlinedStyle"
android:layout_width="48dp"
android:layout_height="51dp"
android:layout_marginTop="4dp"
android:layout_marginEnd="116dp"
android:backgroundTint="@color/white"
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/SentenceAttributeEditText"
android:layout_width="189dp"
android:layout_height="61dp"
android:hint="@string/sentence"
app:layout_constraintBottom_toTopOf="@+id/SentenceAttributeSlider"
app:layout_constraintEnd_toEndOf="@+id/SentenceAttributeSlider"
app:layout_constraintTop_toBottomOf="@+id/SentenceAttributeSlider" />
app:layout_constraintHorizontal_bias="1.0"
app:layout_constraintStart_toEndOf="@+id/textView2"
app:layout_constraintTop_toBottomOf="@+id/space3"
app:layout_constraintVertical_bias="0.323" />

<com.google.android.material.textview.MaterialTextView
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
android:layout_marginStart="44dp"
android:layout_marginTop="44dp"
android:text="@string/sentence_color"
android:textColor="@color/white"
app:layout_constraintBottom_toBottomOf="@+id/SentenceAttributeColorPicker"
app:layout_constraintEnd_toStartOf="@+id/SentenceAttributeColorPicker"
app:layout_constraintTop_toTopOf="@+id/SentenceAttributeColorPicker"
app:layout_constraintVertical_bias="0.593" />
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/textView" />

<com.google.android.material.textview.MaterialTextView
<TextView
android:id="@+id/textView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand All @@ -94,7 +107,7 @@
app:layout_constraintTop_toTopOf="@+id/SentenceAttributeSlider"
app:layout_constraintVertical_bias="0.6" />

<com.google.android.material.textview.MaterialTextView
<TextView
android:id="@+id/SentenceAttributeTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand All @@ -106,7 +119,7 @@
app:layout_constraintVertical_bias="0.242"
tools:ignore="HardcodedText" />

<com.google.android.material.textview.MaterialTextView
<TextView
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand All @@ -117,17 +130,5 @@
app:layout_constraintTop_toBottomOf="@+id/space3"
app:layout_constraintVertical_bias="0.793" />

<com.google.android.material.textfield.TextInputEditText
android:id="@+id/SentenceAttributeEditText"
android:layout_width="191dp"
android:layout_height="42dp"
android:hint="@string/sentence"
app:layout_constraintBottom_toTopOf="@+id/SentenceAttributeSlider"
app:layout_constraintEnd_toEndOf="@+id/SentenceAttributeSlider"
app:layout_constraintHorizontal_bias="1.0"
app:layout_constraintStart_toEndOf="@+id/textView2"
app:layout_constraintTop_toBottomOf="@+id/space3"
app:layout_constraintVertical_bias="0.625" />


</androidx.constraintlayout.widget.ConstraintLayout>
8 changes: 4 additions & 4 deletions app/src/main/res/layout/themes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,28 +16,28 @@
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.466">

<com.google.android.material.radiobutton.MaterialRadioButton
<RadioButton
android:id="@+id/follow_system"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:buttonTint="?colorOnSurface"
android:text="@string/follow_system" />

<com.google.android.material.radiobutton.MaterialRadioButton
<RadioButton
android:id="@+id/light_mode"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:buttonTint="?colorOnSurface"
android:text="@string/light_mode" />

<com.google.android.material.radiobutton.MaterialRadioButton
<RadioButton
android:id="@+id/grey_mode"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:buttonTint="?colorOnSurface"
android:text="@string/grey_mode" />

<com.google.android.material.radiobutton.MaterialRadioButton
<RadioButton
android:id="@+id/dark_mode"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ buildscript {

}
dependencies {
classpath 'com.android.tools.build:gradle:4.1.1'
classpath 'com.android.tools.build:gradle:4.1.2'


// NOTE: Do not place your application dependencies here; they belong
Expand Down

0 comments on commit 783a6c6

Please sign in to comment.