diff options
author | Arne Schwabe <arne@rfc2549.org> | 2013-11-21 09:10:05 +0100 |
---|---|---|
committer | Arne Schwabe <arne@rfc2549.org> | 2013-11-21 09:10:05 +0100 |
commit | d526f083ea9c9ebc08c7d6ca54ab7e69841eeb31 (patch) | |
tree | 3596f528d58acc678585b9fbe56d813fe507acf0 | |
parent | d93401d0c6d694cff4ef5ab1e020ed44a62b43bf (diff) |
Fix log window in landscape
-rw-r--r-- | res/layout/log_window.xml | 22 | ||||
-rw-r--r-- | src/de/blinkt/openvpn/LogWindow.java | 7 |
2 files changed, 14 insertions, 15 deletions
diff --git a/res/layout/log_window.xml b/res/layout/log_window.xml index c814e729..56c3e349 100644 --- a/res/layout/log_window.xml +++ b/res/layout/log_window.xml @@ -1,15 +1,7 @@ -<?xml version="1.0" encoding="utf-8"?> - -<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:tools="http://schemas.android.com/tools" - android:orientation="vertical" - android:layout_width="match_parent" - android:layout_height="match_parent"> - - <fragment - android:layout_width="fill_parent" - android:layout_height="wrap_content" - android:name="de.blinkt.openvpn.fragments.LogFragment" - android:id="@+id/fragment" - tools:layout="@layout/log_fragment"/> -</LinearLayout>
\ No newline at end of file +<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" + android:id="@+id/container" + android:layout_width="match_parent" + android:layout_height="match_parent" + tools:context=".LogWindow" + tools:ignore="MergeRootFrame" />
\ No newline at end of file diff --git a/src/de/blinkt/openvpn/LogWindow.java b/src/de/blinkt/openvpn/LogWindow.java index 843f85cc..641b2416 100644 --- a/src/de/blinkt/openvpn/LogWindow.java +++ b/src/de/blinkt/openvpn/LogWindow.java @@ -3,6 +3,7 @@ package de.blinkt.openvpn; import android.app.Activity; import android.os.Bundle; import android.view.MenuItem; +import de.blinkt.openvpn.fragments.LogFragment; /** * Created by arne on 13.10.13. @@ -14,6 +15,12 @@ public class LogWindow extends Activity { setContentView(R.layout.log_window); getActionBar().setDisplayHomeAsUpEnabled(true); + if (savedInstanceState == null) { + getFragmentManager().beginTransaction() + .add(R.id.container, new LogFragment()) + .commit(); + } + } |