some multi-window optimizations. set min width to 300
This commit is contained in:
parent
e33d8451a8
commit
76cbb4f727
|
@ -40,6 +40,8 @@
|
|||
android:name=".ui.ConversationActivity"
|
||||
android:label="@string/app_name"
|
||||
android:launchMode="singleTask"
|
||||
android:minWidth="300dp"
|
||||
android:minHeight="300dp"
|
||||
android:windowSoftInputMode="stateHidden">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
|
@ -91,13 +93,11 @@
|
|||
<activity
|
||||
android:name=".ui.WelcomeActivity"
|
||||
android:label="@string/app_name"
|
||||
android:launchMode="singleTask"
|
||||
android:screenOrientation="portrait" />
|
||||
android:launchMode="singleTask"/>
|
||||
<activity
|
||||
android:name=".ui.MagicCreateActivity"
|
||||
android:label="@string/create_account"
|
||||
android:launchMode="singleTask"
|
||||
android:screenOrientation="portrait" />
|
||||
android:launchMode="singleTask"/>
|
||||
<activity
|
||||
android:name=".ui.SetPresenceActivity"
|
||||
android:configChanges="orientation|screenSize"
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package eu.siacs.conversations.ui;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.content.pm.ActivityInfo;
|
||||
import android.os.Bundle;
|
||||
import android.text.Editable;
|
||||
import android.text.TextWatcher;
|
||||
|
@ -39,6 +40,9 @@ public class MagicCreateActivity extends XmppActivity implements TextWatcher {
|
|||
|
||||
@Override
|
||||
protected void onCreate(final Bundle savedInstanceState) {
|
||||
if (getResources().getBoolean(R.bool.portrait_only)) {
|
||||
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
|
||||
}
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.magic_create);
|
||||
mFullJidDisplay = (TextView) findViewById(R.id.full_jid);
|
||||
|
|
|
@ -2,6 +2,7 @@ package eu.siacs.conversations.ui;
|
|||
|
||||
import android.app.Activity;
|
||||
import android.content.Intent;
|
||||
import android.content.pm.ActivityInfo;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
|
@ -12,6 +13,9 @@ public class WelcomeActivity extends Activity {
|
|||
|
||||
@Override
|
||||
protected void onCreate(final Bundle savedInstanceState) {
|
||||
if (getResources().getBoolean(R.bool.portrait_only)) {
|
||||
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
|
||||
}
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.welcome);
|
||||
final Button createAccount = (Button) findViewById(R.id.create_account);
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="default_resource">Tablet</string>
|
||||
<bool name="portrait_only">false</bool>
|
||||
</resources>
|
|
@ -0,0 +1,3 @@
|
|||
<resources>
|
||||
<dimen name="conversations_overview_width">276dp</dimen>
|
||||
</resources>
|
|
@ -1,4 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="default_resource">Phone</string>
|
||||
<bool name="portrait_only">true</bool>
|
||||
</resources>
|
Loading…
Reference in New Issue