Browse Source

Visibility fixes in progress bar

David A. Velasco 12 years ago
parent
commit
1c978b8aaf
1 changed files with 5 additions and 1 deletions
  1. 5 1
      src/com/owncloud/android/ui/fragment/FileDetailFragment.java

+ 5 - 1
src/com/owncloud/android/ui/fragment/FileDetailFragment.java

@@ -365,7 +365,6 @@ public class FileDetailFragment extends SherlockFragment implements
                     // update ui 
                     boolean inDisplayActivity = getActivity() instanceof FileDisplayActivity;
                     getActivity().showDialog((inDisplayActivity)? FileDisplayActivity.DIALOG_SHORT_WAIT : FileDetailActivity.DIALOG_SHORT_WAIT);
-                    setButtonsForTransferring(); // disable button immediately, although the synchronization does not result in a file transference
                     
                 }
                 break;
@@ -776,6 +775,8 @@ public class FileDetailFragment extends SherlockFragment implements
             // hides the progress bar
             ProgressBar progressBar = (ProgressBar)getView().findViewById(R.id.fdProgressBar);
             progressBar.setVisibility(View.GONE);
+            TextView progressText = (TextView)getView().findViewById(R.id.fdProgressText);
+            progressText.setVisibility(View.GONE);
         }
     }
 
@@ -795,6 +796,8 @@ public class FileDetailFragment extends SherlockFragment implements
             // hides the progress bar
             ProgressBar progressBar = (ProgressBar)getView().findViewById(R.id.fdProgressBar);
             progressBar.setVisibility(View.GONE);
+            TextView progressText = (TextView)getView().findViewById(R.id.fdProgressText);
+            progressText.setVisibility(View.GONE);
         }
     }
     
@@ -1092,6 +1095,7 @@ public class FileDetailFragment extends SherlockFragment implements
             
         } else {
             if (operation.transferWasRequested()) {
+                setButtonsForTransferring();
                 mContainerActivity.onFileStateChanged();    // this is not working; FileDownloader won't do NOTHING at all until this method finishes, so 
                                                             // checking the service to see if the file is downloading results in FALSE
             } else {