mirror of
https://github.com/nextcloud/android.git
synced 2024-11-25 14:45:47 +03:00
More refactoring
This commit is contained in:
parent
896f145cf6
commit
db0f0001f9
10 changed files with 667 additions and 665 deletions
|
@ -8,6 +8,6 @@
|
|||
android:id="@+id/fileDetail"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
class="eu.alefzero.owncloud.FileDetail" />
|
||||
class="eu.alefzero.owncloud.ui.fragment.FileDetail" />
|
||||
|
||||
</LinearLayout>
|
49
res/layout/files.xml
Normal file
49
res/layout/files.xml
Normal file
|
@ -0,0 +1,49 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
android:background="#F7F7F7"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout1"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<fragment
|
||||
android:id="@+id/actionBar"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="fill_parent"
|
||||
class="eu.alefzero.owncloud.ui.fragment.ActionBar">
|
||||
<!-- Preview: layout=@layout/action_bar -->
|
||||
</fragment>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout2"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content" >
|
||||
|
||||
<fragment
|
||||
android:id="@+id/fileList"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="fill_parent"
|
||||
android:layout_weight="1"
|
||||
class="eu.alefzero.owncloud.ui.fragment.FileList" >
|
||||
|
||||
<!-- Preview: layout=@layout/list_layout -->
|
||||
</fragment>
|
||||
|
||||
<fragment
|
||||
android:id="@+id/fileDetail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="fill_parent"
|
||||
android:layout_weight="2"
|
||||
class="eu.alefzero.owncloud.ui.fragment.FileDetail" >
|
||||
|
||||
<!-- Preview: layout=@layout/file_details -->
|
||||
</fragment>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
|
@ -1,26 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
android:background="#F7F7F7"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<fragment
|
||||
android:id="@+id/actionBar"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
class="eu.alefzero.owncloud.ui.fragment.ActionBar" >
|
||||
<!-- Preview: layout=@layout/action_bar -->
|
||||
</fragment>
|
||||
|
||||
<fragment
|
||||
android:id="@+id/landingPage"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
class="eu.alefzero.owncloud.ui.fragment.LandingPageFragment" >
|
||||
<!-- Preview: layout=@layout/landing_page_fragment -->
|
||||
</fragment>
|
||||
|
||||
|
||||
|
||||
</LinearLayout>
|
|
@ -5,45 +5,22 @@
|
|||
android:background="#F7F7F7"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout1"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<fragment
|
||||
android:id="@+id/actionBar"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
class="eu.alefzero.owncloud.ui.fragment.ActionBar" >
|
||||
<!-- Preview: layout=@layout/action_bar -->
|
||||
</fragment>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout2"
|
||||
<fragment
|
||||
android:id="@+id/landingPage"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content" >
|
||||
|
||||
<fragment
|
||||
android:id="@+id/fileList"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="fill_parent"
|
||||
android:layout_weight="1"
|
||||
class="eu.alefzero.owncloud.ui.fragment.FileList" >
|
||||
|
||||
<!-- Preview: layout=@layout/list_layout -->
|
||||
android:layout_height="wrap_content"
|
||||
class="eu.alefzero.owncloud.ui.fragment.LandingPageFragment" >
|
||||
<!-- Preview: layout=@layout/landing_page_fragment -->
|
||||
</fragment>
|
||||
|
||||
<fragment
|
||||
android:id="@+id/fileDetail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="fill_parent"
|
||||
android:layout_weight="2"
|
||||
class="eu.alefzero.owncloud.FileDetail" >
|
||||
|
||||
<!-- Preview: layout=@layout/file_details -->
|
||||
</fragment>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
|
@ -1,11 +1,11 @@
|
|||
package eu.alefzero.owncloud.ui;
|
||||
|
||||
|
||||
import eu.alefzero.owncloud.FileDetail;
|
||||
import eu.alefzero.owncloud.R;
|
||||
import eu.alefzero.owncloud.R.id;
|
||||
import eu.alefzero.owncloud.R.layout;
|
||||
import eu.alefzero.owncloud.ui.fragment.ActionBar;
|
||||
import eu.alefzero.owncloud.ui.fragment.FileDetail;
|
||||
import android.app.Activity;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
|
|
|
@ -54,7 +54,6 @@ import android.widget.ImageView;
|
|||
import android.widget.ListView;
|
||||
import android.widget.TextView;
|
||||
import eu.alefzero.owncloud.DbHandler;
|
||||
import eu.alefzero.owncloud.FileDetail;
|
||||
import eu.alefzero.owncloud.R;
|
||||
import eu.alefzero.owncloud.R.id;
|
||||
import eu.alefzero.owncloud.R.layout;
|
||||
|
@ -62,6 +61,7 @@ import eu.alefzero.owncloud.R.menu;
|
|||
import eu.alefzero.owncloud.R.string;
|
||||
import eu.alefzero.owncloud.authenticator.AccountAuthenticator;
|
||||
import eu.alefzero.owncloud.db.ProviderMeta.ProviderTableMeta;
|
||||
import eu.alefzero.owncloud.ui.fragment.FileDetail;
|
||||
import eu.alefzero.owncloud.ui.fragment.FileList;
|
||||
import eu.alefzero.owncloud.ui.fragment.ActionBar;
|
||||
public class FileDisplayActivity extends FragmentActivity {
|
||||
|
@ -78,7 +78,7 @@ public class FileDisplayActivity extends FragmentActivity {
|
|||
public void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
getWindow().requestFeature(Window.FEATURE_NO_TITLE);
|
||||
setContentView(R.layout.main);
|
||||
setContentView(R.layout.files);
|
||||
|
||||
FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
|
||||
//ft.add(R.id.actionBar, new ActionBar());
|
||||
|
|
|
@ -41,7 +41,7 @@ public class LandingActivity extends FragmentActivity implements OnClickListener
|
|||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.landing_page);
|
||||
setContentView(R.layout.main);
|
||||
|
||||
// Check, if there are ownCloud accounts
|
||||
if(!accountsAreSetup()){
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
package eu.alefzero.owncloud;
|
||||
package eu.alefzero.owncloud.ui.fragment;
|
||||
|
||||
import eu.alefzero.owncloud.R;
|
||||
import eu.alefzero.owncloud.R.id;
|
||||
import eu.alefzero.owncloud.R.layout;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.support.v4.app.Fragment;
|
|
@ -1,6 +1,5 @@
|
|||
package eu.alefzero.owncloud.ui.fragment;
|
||||
|
||||
import eu.alefzero.owncloud.FileDetail;
|
||||
import eu.alefzero.owncloud.R;
|
||||
import eu.alefzero.owncloud.R.id;
|
||||
import eu.alefzero.owncloud.authenticator.AccountAuthenticator;
|
||||
|
|
Loading…
Reference in a new issue