+
+ public void startSyncFolderOperation(OCFile folder) {
+ long currentSyncTime = System.currentTimeMillis();
+
+ mSyncInProgress = true;
+
+ // perform folder synchronization
+ RemoteOperation synchFolderOp = new SynchronizeFolderOperation( folder,
+ currentSyncTime,
+ false,
+ getStorageManager(),
+ getAccount(),
+ getApplicationContext()
+ );
+ synchFolderOp.execute(getAccount(), this, null, null, this);
+
+ setSupportProgressBarIndeterminateVisibility(true);
+ }
+
+
+ private void startGetShares() {
+ // Get shared files/folders
+ Intent intent = new Intent(this, OperationsService.class);
+ intent.putExtra(OperationsService.EXTRA_ACCOUNT, getAccount());
+ startService(intent);
+
+ mRefreshSharesInProgress = true;
+ }
+
+
+ public void unshareFileWithLink(OCFile file) {
+
+ if (isSharedSupported()) {
+ // Unshare the file
+ UnshareLinkOperation unshare = new UnshareLinkOperation(file);
+ unshare.execute(getStorageManager(), this, this, mHandler, this);
+
+ setSupportProgressBarIndeterminateVisibility(true);
+ } else {
+ // Show a Message
+ Toast t = Toast.makeText(this, getString(R.string.share_link_no_support_share_api), Toast.LENGTH_LONG);
+ t.show();
+
+ }
+ }