Skip to content

Commit

Permalink
feat(main menu gui): main menu gui added
Browse files Browse the repository at this point in the history
  • Loading branch information
jcrucesdeveloper committed Feb 11, 2023
1 parent 8881274 commit c140cf4
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 51 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ public class MainActivity extends AppCompatActivity {
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_NO);
}

public void goNextActivity(View view) {
Expand Down
83 changes: 49 additions & 34 deletions app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,46 +4,61 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/main_menu_background"
tools:context=".activities.MainActivity">

<TextView
android:id="@+id/textView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Hello World!"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />

<Button
android:id="@+id/button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="168dp"
android:layout_marginEnd="149dp"
android:layout_marginBottom="272dp"
android:onClick="goNextActivity"
android:text="Button"
app:layout_constraintBottom_toBottomOf="parent"
<ImageView
android:id="@+id/imageViewButtonPlay"
android:layout_width="253dp"
android:layout_height="202dp"
android:layout_marginTop="76dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.497"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/textView" />
app:layout_constraintTop_toTopOf="parent"
app:srcCompat="@drawable/logo" />

<Button
android:id="@+id/resetButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="168dp"
android:layout_marginEnd="149dp"
android:layout_marginBottom="16dp"
android:onClick="resetButton"
android:text="Button"
app:layout_constraintBottom_toBottomOf="parent"
<ImageView
android:id="@+id/imageView4"
android:layout_width="300dp"
android:layout_height="130dp"
android:layout_marginTop="2dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/textView"
app:layout_constraintVertical_bias="1.0" />
app:layout_constraintTop_toBottomOf="@+id/imageViewButtonPlay"
app:srcCompat="@drawable/main_menu_button_play" />

<ImageView
android:id="@+id/imageView6"
android:layout_width="104dp"
android:layout_height="97dp"
android:layout_marginStart="48dp"
android:layout_marginTop="-16dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/imageView4"
app:srcCompat="@drawable/main_menu_button_information" />

<ImageView
android:id="@+id/imageView7"
android:layout_width="95dp"
android:layout_height="95dp"
android:layout_marginStart="8dp"
android:layout_marginTop="-16dp"
android:layout_marginEnd="8dp"
app:layout_constraintEnd_toStartOf="@+id/imageView8"
app:layout_constraintStart_toEndOf="@+id/imageView6"
app:layout_constraintTop_toBottomOf="@+id/imageView4"
app:srcCompat="@drawable/main_menu_button_reset" />

<ImageView
android:id="@+id/imageView8"
android:layout_width="95dp"
android:layout_height="95dp"
android:layout_marginTop="-16dp"
android:layout_marginEnd="48dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@+id/imageView7"
app:layout_constraintTop_toBottomOf="@+id/imageView4"
app:srcCompat="@drawable/main_menu_configuration" />

</androidx.constraintlayout.widget.ConstraintLayout>
16 changes: 0 additions & 16 deletions app/src/main/res/values-night/themes.xml

This file was deleted.

1 change: 1 addition & 0 deletions app/src/main/res/values/themes.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<resources xmlns:tools="http://schemas.android.com/tools">
<!-- Base application theme. -->
<style name="Theme.MetroMetro" parent="Theme.MaterialComponents.Light.NoActionBar">
<item name="android:forceDarkAllowed" tools:targetApi="q">false</item>
<!-- Primary brand color. -->
<item name="colorPrimary">@color/purple_500</item>
<item name="colorPrimaryVariant">@color/purple_700</item>
Expand Down

0 comments on commit c140cf4

Please sign in to comment.