adding use ssl mode
[pub/Android/ownCloud.git] / src / eu / alefzero / owncloud / ui / activity / Preferences.java
index aec2f94..70f3362 100644 (file)
@@ -36,6 +36,7 @@ import android.view.ContextMenu.ContextMenuInfo;
 import android.view.View;\r
 import android.widget.AdapterView.AdapterContextMenuInfo;\r
 \r
+import com.actionbarsherlock.app.ActionBar;\r
 import com.actionbarsherlock.app.SherlockPreferenceActivity;\r
 import com.actionbarsherlock.view.Menu;\r
 import com.actionbarsherlock.view.MenuInflater;\r
@@ -70,6 +71,8 @@ public class Preferences extends SherlockPreferenceActivity implements OnPrefere
     addPreferencesFromResource(R.xml.preferences);\r
     registerForContextMenu(getListView());\r
     populateAccountList();\r
+    ActionBar actionBar = getSherlock().getActionBar();\r
+    actionBar.setDisplayHomeAsUpEnabled(true);\r
     //populateSessionList();\r
   }\r
   \r
@@ -151,6 +154,11 @@ public class Preferences extends SherlockPreferenceActivity implements OnPrefere
         mSessions.remove(ocs);\r
         getPreferenceScreen().removePreference(getPreferenceScreen().getPreference(mSelectedMenuItem+1));\r
         break;\r
+      case android.R.id.home:\r
+         intent = new Intent(getBaseContext(), LandingActivity.class);\r
+         intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\r
+         startActivity(intent);\r
+         break;\r
       default:\r
         Log.w(TAG, "Unknown menu item triggered");\r
         return false;\r