Disable auto activation of the on screen keyboard in ChangeStatus activity
authorDa Risk <darisk972@gmail.com>
Sun, 11 Apr 2010 19:32:25 +0200
changeset 725 559845cadddb
parent 722 31858ca72190
child 726 344a06703472
Disable auto activation of the on screen keyboard in ChangeStatus activity Fix #254
AndroidManifest.xml
res/layout/changestatus.xml
--- a/AndroidManifest.xml	Thu Apr 01 22:22:34 2010 +0200
+++ b/AndroidManifest.xml	Sun Apr 11 19:32:25 2010 +0200
@@ -29,7 +29,8 @@
 					android:name="com.beem.project.beem.service.XmppConnectionAdapter.CONNECTION_CLOSED" />
 			</intent-filter>
 		</activity>
-		<activity android:name=".ui.ChangeStatus" android:label="@string/ChangeStatusActTitle">
+		<activity android:name=".ui.ChangeStatus" android:label="@string/ChangeStatusActTitle"
+		    android:windowSoftInputMode="stateHidden" >
 			<intent-filter android:label="Beem Connection">
 				<action
 					android:name="com.beem.project.beem.service.XmppConnectionAdapter.CONNECTION_CLOSED" />
--- a/res/layout/changestatus.xml	Thu Apr 01 22:22:34 2010 +0200
+++ b/res/layout/changestatus.xml	Sun Apr 11 19:32:25 2010 +0200
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-	android:layout_width="fill_parent" android:layout_height="fill_parent"
+	android:layout_width="fill_parent" android:layout_height="wrap_content"
 	android:orientation="vertical">
 	<RelativeLayout android:orientation="vertical"
 		android:layout_width="fill_parent" android:layout_height="fill_parent"
@@ -13,30 +13,36 @@
 			android:drawSelectorOnTop="true" android:layout_below="@id/ChangeStatusTypeLabel" />
 		<TextView android:id="@+id/ChangeStatusMessageLabel"
 			android:layout_width="fill_parent" android:layout_height="wrap_content"
-			android:text="@string/ChangeStatusMessage" style="@style/Label"
-			android:layout_below="@id/ChangeStatusSpinner" />
+			android:layout_below="@id/ChangeStatusSpinner"
+			style="@style/Label"
+			android:inputType="textShortMessage|textCapSentences|textAutoCorrect|textMultiLine|textImeMultiLine"
+			android:imeOptions="actionDone"
+			android:selectAllOnFocus="true"
+			/>
 		<EditText android:id="@+id/ChangeStatusMessage"
 			android:inputType="textShortMessage|textAutoCorrect"
 			android:imeOptions="actionDone" android:layout_width="fill_parent"
 			android:layout_height="wrap_content" android:layout_below="@id/ChangeStatusMessageLabel"
 			android:layout_marginBottom="18dp" />
 		<LinearLayout android:id="@+id/ChangeStatusButtons"
-			android:layout_width="fill_parent" android:layout_height="wrap_content"
-			android:orientation="horizontal" android:layout_below="@id/ChangeStatusMessage"
-			android:layout_alignParentBottom="true">
-			<Button android:id="@+id/ChangeStatusOk" android:layout_width="fill_parent"
-				android:layout_height="wrap_content" android:layout_weight="1"
+			android:layout_height="wrap_content" android:layout_width="fill_parent"
+			android:layout_below="@id/ChangeStatusMessage"
+			android:orientation="horizontal">
+			<Button android:id="@+id/ChangeStatusOk"
+				android:layout_width="fill_parent" android:layout_height="wrap_content"
+				android:layout_weight="1"
 				android:text="@string/UpdateButton" android:textStyle="bold"
 				android:textSize="18sp" android:textColor="#333333" />
 			<Button android:id="@+id/ChangeStatusClear"
 				android:layout_width="fill_parent" android:layout_height="wrap_content"
-				android:layout_weight="1" android:text="@string/ClearButton"
+				android:layout_weight="1"
+				android:text="@string/ClearButton"
 				android:textStyle="bold" android:textColor="#333333"
 				android:textSize="18sp" />
 		</LinearLayout>
 		<Button android:id="@+id/OpenContactList" android:layout_width="fill_parent"
 			android:layout_height="wrap_content" android:text="@string/OpenContactList"
 			android:layout_below="@+id/ChangeStatusButtons" android:textStyle="bold" android:textColor="#333333"
-				android:textSize="18sp" />
+			android:textSize="18sp" />
 	</RelativeLayout>
 </ScrollView>