Browse Source

remove preferences its not needed for now

Bartek Przybylski 13 years ago
parent
commit
4ee419da91

+ 1 - 1
res/menu/menu.xml

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 <menu
   xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:id="@+id/startSync" android:title="Sync account" android:showAsAction="ifRoom" android:icon="@drawable/ic_action_refresh"></item><item android:title="Settings" android:icon="@android:drawable/ic_menu_preferences" android:id="@+id/settingsItem" android:showAsAction="never"></item>
+    <item android:id="@+id/startSync" android:title="Sync account" android:showAsAction="ifRoom" android:icon="@drawable/ic_action_refresh"></item>
     <item android:id="@+id/createDirectoryItem" android:title="Create Directory" android:icon="@drawable/ic_action_create_dir" android:showAsAction="ifRoom"></item>
     
     <item android:id="@+id/search" android:icon="@drawable/ic_action_search" android:showAsAction="ifRoom"></item>

+ 0 - 5
res/menu/prefs_menu.xml

@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<menu
-  xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:id="@+id/addSessionItem" android:icon="@+android:drawable/ic_menu_add" android:title="@string/prefs_add_session"></item>
-</menu>

+ 31 - 35
src/eu/alefzero/owncloud/ui/activity/FileDisplayActivity.java

@@ -177,6 +177,7 @@ public class FileDisplayActivity extends SherlockFragmentActivity implements
         setProgressBarIndeterminateVisibility(false);
         // if (getSupportFragmentManager().findFragmentById(R.id.fileList) ==
         // null)
+        Log.e("ASDaaa", "ASDaaa");
         setContentView(R.layout.files);
 
     }
@@ -185,41 +186,36 @@ public class FileDisplayActivity extends SherlockFragmentActivity implements
     public boolean onOptionsItemSelected(MenuItem item) {
         boolean retval = true;
         switch (item.getItemId()) {
-        case R.id.settingsItem: {
-            Intent i = new Intent(this, Preferences.class);
-            startActivity(i);
-            break;
-        }
-        case R.id.createDirectoryItem: {
-            showDialog(DIALOG_CREATE_DIR);
-            break;
-        }
-        case R.id.startSync: {
-            Bundle bundle = new Bundle();
-            bundle.putBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, true);
-            ContentResolver.requestSync(
-                    AccountUtils.getCurrentOwnCloudAccount(this),
-                    "org.owncloud", bundle);
-            break;
-        }
-        case R.id.action_upload: {
-            Intent action = new Intent(Intent.ACTION_GET_CONTENT);
-            action = action.setType("*/*")
-                    .addCategory(Intent.CATEGORY_OPENABLE);
-            startActivityForResult(
-                    Intent.createChooser(action, "Upload file from..."),
-                    ACTION_SELECT_FILE);
-            break;
-        }
-
-        case android.R.id.home: {
-            Intent i = new Intent(this, AccountSelectActivity.class);
-            startActivity(i);
-            finish();
-            break;
-        }
-        default:
-            retval = false;
+            case R.id.createDirectoryItem: {
+                showDialog(DIALOG_CREATE_DIR);
+                break;
+            }
+            case R.id.startSync: {
+                Bundle bundle = new Bundle();
+                bundle.putBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, true);
+                ContentResolver.requestSync(
+                        AccountUtils.getCurrentOwnCloudAccount(this),
+                        "org.owncloud", bundle);
+                break;
+            }
+            case R.id.action_upload: {
+                Intent action = new Intent(Intent.ACTION_GET_CONTENT);
+                action = action.setType("*/*")
+                        .addCategory(Intent.CATEGORY_OPENABLE);
+                startActivityForResult(
+                        Intent.createChooser(action, "Upload file from..."),
+                        ACTION_SELECT_FILE);
+                break;
+            }
+    
+            case android.R.id.home: {
+                Intent i = new Intent(this, AccountSelectActivity.class);
+                startActivity(i);
+                finish();
+                break;
+            }
+            default:
+                retval = false;
         }
         return retval;
     }