Loading packages/DocumentsUI/src/com/android/documentsui/BaseActivity.java +4 −0 Original line number Diff line number Diff line Loading @@ -491,6 +491,10 @@ public abstract class BaseActivity extends Activity implements SearchManagerList return; } if (DirectoryFragment.get(getFragmentManager()).onBackPressed()) { return; } if (!mState.hasLocationChanged()) { super.onBackPressed(); return; Loading packages/DocumentsUI/src/com/android/documentsui/dirlist/DirectoryFragment.java +11 −4 Original line number Diff line number Diff line Loading @@ -642,10 +642,7 @@ public class DirectoryFragment extends Fragment implements DocumentsAdapter.Envi return true; case R.id.menu_copy_to_clipboard: if (!selection.isEmpty()) { copySelectionToClipboard(selection); mode.finish(); } copySelectedToClipboard(); return true; case R.id.menu_select_all: Loading @@ -664,6 +661,15 @@ public class DirectoryFragment extends Fragment implements DocumentsAdapter.Envi } } public final boolean onBackPressed() { if (mSelectionManager.hasSelection()) { if (DEBUG) Log.d(TAG, "Clearing selection on back pressed."); mSelectionManager.clearSelection(); return true; } return false; } private void cancelThumbnailTask(View view) { final ImageView iconThumb = (ImageView) view.findViewById(R.id.icon_thumb); if (iconThumb != null) { Loading Loading @@ -993,6 +999,7 @@ public class DirectoryFragment extends Fragment implements DocumentsAdapter.Envi Selection selection = mSelectionManager.getSelection(new Selection()); if (!selection.isEmpty()) { copySelectionToClipboard(selection); mSelectionManager.clearSelection(); } } Loading Loading
packages/DocumentsUI/src/com/android/documentsui/BaseActivity.java +4 −0 Original line number Diff line number Diff line Loading @@ -491,6 +491,10 @@ public abstract class BaseActivity extends Activity implements SearchManagerList return; } if (DirectoryFragment.get(getFragmentManager()).onBackPressed()) { return; } if (!mState.hasLocationChanged()) { super.onBackPressed(); return; Loading
packages/DocumentsUI/src/com/android/documentsui/dirlist/DirectoryFragment.java +11 −4 Original line number Diff line number Diff line Loading @@ -642,10 +642,7 @@ public class DirectoryFragment extends Fragment implements DocumentsAdapter.Envi return true; case R.id.menu_copy_to_clipboard: if (!selection.isEmpty()) { copySelectionToClipboard(selection); mode.finish(); } copySelectedToClipboard(); return true; case R.id.menu_select_all: Loading @@ -664,6 +661,15 @@ public class DirectoryFragment extends Fragment implements DocumentsAdapter.Envi } } public final boolean onBackPressed() { if (mSelectionManager.hasSelection()) { if (DEBUG) Log.d(TAG, "Clearing selection on back pressed."); mSelectionManager.clearSelection(); return true; } return false; } private void cancelThumbnailTask(View view) { final ImageView iconThumb = (ImageView) view.findViewById(R.id.icon_thumb); if (iconThumb != null) { Loading Loading @@ -993,6 +999,7 @@ public class DirectoryFragment extends Fragment implements DocumentsAdapter.Envi Selection selection = mSelectionManager.getSelection(new Selection()); if (!selection.isEmpty()) { copySelectionToClipboard(selection); mSelectionManager.clearSelection(); } } Loading