Merge branch 'master' of github:jsmaniac/2011-m1s2-ter
This commit is contained in:
commit
c5d63679f2
|
@ -3,17 +3,17 @@
|
||||||
android:layout_height="fill_parent" android:orientation="vertical"
|
android:layout_height="fill_parent" android:orientation="vertical"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
<LinearLayout android:id="@+id/widget40"
|
<LinearLayout android:layout_width="fill_parent"
|
||||||
android:layout_width="fill_parent" android:layout_height="fill_parent"
|
android:layout_height="fill_parent" android:orientation="vertical"
|
||||||
android:orientation="vertical" android:layout_weight="1">
|
android:layout_weight="1">
|
||||||
|
|
||||||
<TextView android:id="@+id/mainWord" android:layout_width="fill_parent"
|
<TextView android:id="@+id/mainWord" android:layout_width="fill_parent"
|
||||||
android:layout_height="wrap_content" android:text="mainWord"
|
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>
|
||||||
<TextView android:id="@+id/currentWord" android:layout_width="fill_parent"
|
<TextView android:id="@+id/currentWord" android:layout_width="fill_parent"
|
||||||
android:layout_height="wrap_content" android:text="currentWord"
|
android:layout_height="wrap_content" android:text="currentWord"
|
||||||
android:textStyle="bold" android:gravity="center">
|
android:textStyle="bold" android:gravity="center" android:textSize="20dip">
|
||||||
</TextView>
|
</TextView>
|
||||||
|
|
||||||
|
|
||||||
|
@ -32,8 +32,8 @@
|
||||||
android:layout_weight="1" android:layout_gravity="bottom">
|
android:layout_weight="1" android:layout_gravity="bottom">
|
||||||
</Button>
|
</Button>
|
||||||
<Button android:id="@+id/trash" android:text="trash"
|
<Button android:id="@+id/trash" android:text="trash"
|
||||||
android:layout_height="wrap_content" android:layout_width="fill_parent"
|
android:layout_width="fill_parent"
|
||||||
android:layout_weight="1" android:layout_gravity="bottom">
|
android:layout_weight="1" android:layout_gravity="bottom" android:layout_height="fill_parent">
|
||||||
</Button>
|
</Button>
|
||||||
<Button android:id="@+id/relation3" android:text="relation3"
|
<Button android:id="@+id/relation3" android:text="relation3"
|
||||||
android:layout_height="wrap_content" android:layout_width="fill_parent"
|
android:layout_height="wrap_content" android:layout_width="fill_parent"
|
||||||
|
|
|
@ -3,8 +3,8 @@
|
||||||
|
|
||||||
<PreferenceCategory android:title="Connexion">
|
<PreferenceCategory android:title="Connexion">
|
||||||
|
|
||||||
<EditTextPreference android:title="Login" android:key="login" android:summary=""/>
|
<EditTextPreference android:title="Login" android:key="login" android:summary="" android:dialogTitle="Entrer nom utilisateur"/>
|
||||||
<EditTextPreference android:title="Mot de Passe" android:key="passwd"/>
|
<EditTextPreference android:title="Mot de Passe" android:key="passwd" android:dialogTitle="Entrer mot de passe" android:password="true"/>
|
||||||
|
|
||||||
</PreferenceCategory>
|
</PreferenceCategory>
|
||||||
<PreferenceCategory android:title="Debug">
|
<PreferenceCategory android:title="Debug">
|
||||||
|
|
|
@ -19,11 +19,17 @@ public class FrontPage extends Activity implements OnClickListener{
|
||||||
public void onCreate(Bundle savedInstanceState) {
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(R.layout.frontpage);
|
setContentView(R.layout.frontpage);
|
||||||
|
|
||||||
// Écoute des clics sur les différents boutons
|
// Écoute des clics sur les différents boutons
|
||||||
((ImageView)findViewById(R.id.prefs)).setOnClickListener(this);
|
((ImageView)findViewById(R.id.prefs)).setOnClickListener(this);
|
||||||
((ImageView)findViewById(R.id.play)).setOnClickListener(this);
|
((ImageView)findViewById(R.id.play)).setOnClickListener(this);
|
||||||
((ImageView)findViewById(R.id.infoButton)).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.
|
// On récupère le nom du joueur des préférences.
|
||||||
SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(this);
|
SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(this);
|
||||||
String loginPref = sp.getString("login", "joueur");
|
String loginPref = sp.getString("login", "joueur");
|
||||||
|
|
|
@ -29,5 +29,12 @@ public class Main extends Activity {
|
||||||
super.onActivityResult(requestCode, resultCode, data);
|
super.onActivityResult(requestCode, resultCode, data);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onStop() {
|
||||||
|
super.onStop();
|
||||||
|
|
||||||
|
finish();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
|
@ -65,6 +65,5 @@ public class Score extends Activity implements OnClickListener{
|
||||||
if (v.getId()==R.id.saw) {
|
if (v.getId()==R.id.saw) {
|
||||||
finish();
|
finish();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user