+
+ } else if (operation instanceof SynchronizeFolderOperation) {
+ onSynchronizeFolderOperationFinish((SynchronizeFolderOperation)operation, result);
+ }
+ }
+
+
+ /**
+ * Updates the view associated to the activity after the finish of an operation trying to synchronize a folder.
+ *
+ * @param operation Synchronize operation performed.
+ * @param result Result of the synchronization.
+ */
+ private void onSynchronizeFolderOperationFinish(SynchronizeFolderOperation operation, RemoteOperationResult result) {
+ if (result.isSuccess()) {
+ refeshListOfFilesFragment();
+
+ } else {
+ try {
+ Toast msg = Toast.makeText(FileDisplayActivity.this, R.string.sync_file_fail_msg, Toast.LENGTH_LONG);
+ msg.show();
+
+ } catch (NotFoundException e) {
+ Log_OC.e(TAG, "Error while trying to show fail message " , e);
+ }