1. Changelog complet des améliorations 2025 :
- ✅ Corrections orthographe (MainActivity, question.json, strings.xml, Jeuxold.java) - ✅ Optimisation aléatoire (instance unique Random) - ✅ Interface utilisateur cohérente (champs dynamiques) - ✅ Slider durée des défis (-5 à +15 manches) - ✅ Gestion intelligente des défis (pas d'accumulation) - ✅ Bug fix fin de jeu (flag isFinishingGame) - ✅ Expansion contenu (50 nouvelles questions, passage de 100 à 150)
This commit is contained in:
@@ -11,70 +11,63 @@
|
||||
<com.google.android.material.appbar.AppBarLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:theme="@style/ThemeOverlay.AppCompat.Dark">
|
||||
|
||||
<androidx.appcompat.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:background="@color/primary"
|
||||
app:popupTheme="@style/ThemeOverlay.AppCompat.Light" />
|
||||
|
||||
</com.google.android.material.appbar.AppBarLayout>
|
||||
android:theme="@style/ThemeOverlay.AppCompat.Dark"/>
|
||||
|
||||
<!-- Main Content -->
|
||||
|
||||
<!-- Floating Action Button -->
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
|
||||
<!-- Title -->
|
||||
<TextView
|
||||
android:id="@+id/Titre"
|
||||
style="@style/BoideloTitle"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:text="@string/bienvenue" />
|
||||
android:id="@+id/Titre"
|
||||
style="@style/BoideloTitle"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:text="@string/bienvenue"/>
|
||||
|
||||
<!-- Player Count Indicator -->
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="16dp"
|
||||
app:cardBackgroundColor="@color/primary_light"
|
||||
app:cardCornerRadius="12dp"
|
||||
app:cardElevation="2dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:padding="12dp">
|
||||
android:layout_marginBottom="16dp"
|
||||
app:cardBackgroundColor="@color/accent"
|
||||
app:cardCornerRadius="12dp"
|
||||
app:cardElevation="2dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:padding="12dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@drawable/ic_player_three"
|
||||
app:tint="@color/white" />
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@drawable/ic_player_three"
|
||||
app:tint="@color/white"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/playerCountText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Joueurs: 0 / min. 3"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
android:id="@+id/playerCountText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Joueurs: 0 / min. 3"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -82,119 +75,120 @@
|
||||
|
||||
<!-- Players Input Card -->
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="16dp"
|
||||
app:cardBackgroundColor="@color/white"
|
||||
app:cardCornerRadius="16dp"
|
||||
app:cardElevation="4dp"
|
||||
app:strokeColor="@color/surface_variant"
|
||||
app:strokeWidth="1dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
android:layout_marginBottom="16dp"
|
||||
app:cardBackgroundColor="@color/white"
|
||||
app:cardCornerRadius="16dp"
|
||||
app:cardElevation="4dp"
|
||||
app:strokeColor="@color/surface_variant"
|
||||
app:strokeWidth="1dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:background="@color/background"
|
||||
android:padding="16dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView2"
|
||||
style="@style/BoideloCaption"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:gravity="center"
|
||||
android:text="@string/laisse_vide_si_il_y_a_pas_assez_de_joueur" />
|
||||
android:id="@+id/textView2"
|
||||
style="@style/BoideloCaption"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:gravity="center"
|
||||
android:text="@string/laisse_vide_si_il_y_a_pas_assez_de_joueur"/>
|
||||
|
||||
<!-- Default Player Inputs -->
|
||||
<com.google.android.material.textfield.TextInputLayout
|
||||
android:id="@+id/textInputLayoutJ1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="12dp"
|
||||
android:hint="@string/nom"
|
||||
app:boxBackgroundColor="@color/surface"
|
||||
app:boxStrokeColor="@color/primary"
|
||||
app:boxStrokeWidth="2dp"
|
||||
app:endIconMode="clear_text"
|
||||
app:errorEnabled="false"
|
||||
app:hintTextColor="@color/text_hint"
|
||||
style="@style/Widget.Material3.TextInputLayout.OutlinedBox">
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/J1"
|
||||
android:id="@+id/textInputLayoutJ1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textPersonName"
|
||||
android:maxLines="1"
|
||||
android:textSize="16sp" />
|
||||
android:layout_marginBottom="12dp"
|
||||
android:hint="@string/nom"
|
||||
app:boxBackgroundColor="@color/surface"
|
||||
app:boxStrokeColor="@color/primary"
|
||||
app:boxStrokeWidth="2dp"
|
||||
app:endIconMode="clear_text"
|
||||
app:errorEnabled="false"
|
||||
app:hintTextColor="@color/text_hint"
|
||||
style="@style/Widget.Material3.TextInputLayout.OutlinedBox">
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/J1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textPersonName"
|
||||
android:maxLines="1"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</com.google.android.material.textfield.TextInputLayout>
|
||||
|
||||
<com.google.android.material.textfield.TextInputLayout
|
||||
android:id="@+id/textInputLayoutJ2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="12dp"
|
||||
android:hint="@string/nom"
|
||||
app:boxBackgroundColor="@color/surface"
|
||||
app:boxStrokeColor="@color/primary"
|
||||
app:boxStrokeWidth="2dp"
|
||||
app:endIconMode="clear_text"
|
||||
app:hintTextColor="@color/text_hint"
|
||||
style="@style/Widget.Material3.TextInputLayout.OutlinedBox">
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/J2"
|
||||
android:id="@+id/textInputLayoutJ2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textPersonName"
|
||||
android:maxLines="1"
|
||||
android:textSize="16sp" />
|
||||
android:layout_marginBottom="12dp"
|
||||
android:hint="@string/nom"
|
||||
app:boxBackgroundColor="@color/surface"
|
||||
app:boxStrokeColor="@color/primary"
|
||||
app:boxStrokeWidth="2dp"
|
||||
app:endIconMode="clear_text"
|
||||
app:hintTextColor="@color/text_hint"
|
||||
style="@style/Widget.Material3.TextInputLayout.OutlinedBox">
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/J2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textPersonName"
|
||||
android:maxLines="1"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</com.google.android.material.textfield.TextInputLayout>
|
||||
|
||||
<com.google.android.material.textfield.TextInputLayout
|
||||
android:id="@+id/textInputLayoutJ3"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="12dp"
|
||||
android:hint="@string/nom"
|
||||
app:boxBackgroundColor="@color/surface"
|
||||
app:boxStrokeColor="@color/primary"
|
||||
app:boxStrokeWidth="2dp"
|
||||
app:endIconMode="clear_text"
|
||||
app:hintTextColor="@color/text_hint"
|
||||
style="@style/Widget.Material3.TextInputLayout.OutlinedBox">
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/J3"
|
||||
android:id="@+id/textInputLayoutJ3"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textPersonName"
|
||||
android:maxLines="1"
|
||||
android:textSize="16sp" />
|
||||
android:layout_marginBottom="12dp"
|
||||
android:hint="@string/nom"
|
||||
app:boxBackgroundColor="@color/surface"
|
||||
app:boxStrokeColor="@color/primary"
|
||||
app:boxStrokeWidth="2dp"
|
||||
app:endIconMode="clear_text"
|
||||
app:hintTextColor="@color/text_hint"
|
||||
style="@style/Widget.Material3.TextInputLayout.OutlinedBox">
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/J3"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textPersonName"
|
||||
android:maxLines="1"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</com.google.android.material.textfield.TextInputLayout>
|
||||
|
||||
<!-- Dynamic Player Input Container -->
|
||||
<LinearLayout
|
||||
android:id="@+id/nameEntryLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical" />
|
||||
android:id="@+id/nameEntryLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"/>
|
||||
|
||||
<!-- Add Player Button -->
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/Validation"
|
||||
style="@style/BoideloButton.Secondary"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:onClick="onClickButton1"
|
||||
android:text="@string/c_ok"
|
||||
app:icon="@android:drawable/ic_input_add"
|
||||
app:iconGravity="textStart" />
|
||||
android:id="@+id/Validation"
|
||||
style="@style/BoideloButton.Secondary"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:onClick="onClickButton1"
|
||||
android:text="@string/c_ok"
|
||||
app:icon="@android:drawable/ic_input_add"
|
||||
app:iconGravity="textStart"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -202,25 +196,23 @@
|
||||
|
||||
<!-- Bottom Spacer for FAB -->
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp" />
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="80dp"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
<!-- Floating Action Button -->
|
||||
<com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton
|
||||
android:id="@+id/Go"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|end"
|
||||
android:layout_margin="16dp"
|
||||
android:onClick="onClickButtonStart"
|
||||
android:text="@string/go"
|
||||
android:textColor="@color/text_primary"
|
||||
app:backgroundTint="@color/accent"
|
||||
app:icon="@android:drawable/ic_media_play"
|
||||
app:iconTint="@color/text_primary" />
|
||||
android:id="@+id/Go"
|
||||
android:layout_width="172dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|end"
|
||||
android:layout_margin="16dp"
|
||||
android:onClick="onClickButtonStart"
|
||||
android:text="@string/go"
|
||||
android:textColor="@color/text_primary"
|
||||
app:backgroundTint="@color/accent"
|
||||
app:icon="@android:drawable/ic_media_play"
|
||||
app:iconTint="@color/text_primary"/>
|
||||
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
|
||||
Reference in New Issue
Block a user