Merge branch 'master' of github:jsmaniac/2011-m1s2-ter

This commit is contained in:
Georges Dupéron 2011-02-03 01:18:47 +01:00
commit c5d63679f2
5 changed files with 23 additions and 11 deletions

View File

@ -3,17 +3,17 @@
android:layout_height="fill_parent" android:orientation="vertical"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout android:id="@+id/widget40"
android:layout_width="fill_parent" android:layout_height="fill_parent"
android:orientation="vertical" android:layout_weight="1">
<LinearLayout android:layout_width="fill_parent"
android:layout_height="fill_parent" android:orientation="vertical"
android:layout_weight="1">
<TextView android:id="@+id/mainWord" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:text="mainWord"
android:textSize="30sp" android:textStyle="bold" android:gravity="center">
android:textStyle="bold" android:gravity="center" android:textSize="30dip">
</TextView>
<TextView android:id="@+id/currentWord" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:text="currentWord"
android:textStyle="bold" android:gravity="center">
android:textStyle="bold" android:gravity="center" android:textSize="20dip">
</TextView>
@ -32,8 +32,8 @@
android:layout_weight="1" android:layout_gravity="bottom">
</Button>
<Button android:id="@+id/trash" android:text="trash"
android:layout_height="wrap_content" android:layout_width="fill_parent"
android:layout_weight="1" android:layout_gravity="bottom">
android:layout_width="fill_parent"
android:layout_weight="1" android:layout_gravity="bottom" android:layout_height="fill_parent">
</Button>
<Button android:id="@+id/relation3" android:text="relation3"
android:layout_height="wrap_content" android:layout_width="fill_parent"

View File

@ -3,8 +3,8 @@
<PreferenceCategory android:title="Connexion">
<EditTextPreference android:title="Login" android:key="login" android:summary=""/>
<EditTextPreference android:title="Mot de Passe" android:key="passwd"/>
<EditTextPreference android:title="Login" android:key="login" android:summary="" android:dialogTitle="Entrer nom utilisateur"/>
<EditTextPreference android:title="Mot de Passe" android:key="passwd" android:dialogTitle="Entrer mot de passe" android:password="true"/>
</PreferenceCategory>
<PreferenceCategory android:title="Debug">

View File

@ -19,11 +19,17 @@ public class FrontPage extends Activity implements OnClickListener{
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.frontpage);
// Écoute des clics sur les différents boutons
((ImageView)findViewById(R.id.prefs)).setOnClickListener(this);
((ImageView)findViewById(R.id.play)).setOnClickListener(this);
((ImageView)findViewById(R.id.infoButton)).setOnClickListener(this);
}
@Override
protected void onStart() {
super.onStart();
// On récupère le nom du joueur des préférences.
SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(this);
String loginPref = sp.getString("login", "joueur");

View File

@ -29,5 +29,12 @@ public class Main extends Activity {
super.onActivityResult(requestCode, resultCode, data);
}
@Override
protected void onStop() {
super.onStop();
finish();
}
}

View File

@ -65,6 +65,5 @@ public class Score extends Activity implements OnClickListener{
if (v.getId()==R.id.saw) {
finish();
}
}
}