X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/5c0e9ca5f2614bc29fd5d18730cc845f482bfa5f..00482b6dcb1e98da39df54374f7098b51d66bee5:/src/com/owncloud/android/ui/activity/UploadPathActivity.java diff --git a/src/com/owncloud/android/ui/activity/UploadPathActivity.java b/src/com/owncloud/android/ui/activity/UploadPathActivity.java index 06f71c64..db704d14 100644 --- a/src/com/owncloud/android/ui/activity/UploadPathActivity.java +++ b/src/com/owncloud/android/ui/activity/UploadPathActivity.java @@ -1,5 +1,7 @@ -/* ownCloud Android client application - * Copyright (C) 2012-2014 ownCloud Inc. +/** + * ownCloud Android client application + * + * Copyright (C) 2015 ownCloud Inc. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2, @@ -18,10 +20,7 @@ package com.owncloud.android.ui.activity; import android.accounts.Account; -import android.content.Intent; - import android.os.Bundle; -import android.view.View; import android.view.View.OnClickListener; import com.owncloud.android.datamodel.OCFile; @@ -33,7 +32,6 @@ public class UploadPathActivity extends FolderPickerActivity implements FileFrag public static final String KEY_INSTANT_UPLOAD_PATH = "INSTANT_UPLOAD_PATH"; - public static final int RESULT_OK_SET_UPLOAD_PATH = 1; @Override protected void onCreate(Bundle savedInstanceState) { @@ -41,6 +39,7 @@ public class UploadPathActivity extends FolderPickerActivity implements FileFrag String instantUploadPath = getIntent().getStringExtra(KEY_INSTANT_UPLOAD_PATH); + // The caller activity (Preferences) is not a FileActivity, so it has no OCFile, only a path. OCFile folder = new OCFile(instantUploadPath); setFile(folder); @@ -68,7 +67,8 @@ public class UploadPathActivity extends FolderPickerActivity implements FileFrag if (!stateWasRecovered) { OCFileListFragment listOfFolders = getListOfFilesFragment(); - listOfFolders.listDirectory(folder); + // TODO Enable when "On Device" is recovered ? + listOfFolders.listDirectory(folder/*, false*/); startSyncFolderOperation(folder, false); } @@ -76,16 +76,4 @@ public class UploadPathActivity extends FolderPickerActivity implements FileFrag updateNavigationElementsInActionBar(); } } - - @Override - public void onClick(View v) { - if (v == mCancelBtn) { - finish(); - } else if (v == mChooseBtn) { - Intent data = new Intent(); - data.putExtra(EXTRA_CURRENT_FOLDER, getCurrentFolder()); - setResult(RESULT_OK_SET_UPLOAD_PATH, data); - finish(); - } - } }