Loading res/values/inspector_strings.xml +2 −0 Original line number Diff line number Diff line Loading @@ -98,6 +98,8 @@ <string name="debug_raw_mimetype" translatable="false">Raw mimetype</string> <!-- String label for developer/debug file details, specifying that a file is an archive. --> <string name="debug_is_archive" translatable="false">Is archive</string> <!-- String label for developer/debug file details, specifying that a directory is blocked from tree. --> <string name="debug_is_blocked_from_tree" translatable="false">Is blocked from tree</string> <!-- String label for developer/debug file details, specifying that a file is a container (like a folder or an archive). --> <string name="debug_is_container" translatable="false">Is container</string> <!-- String label for developer/debug file details, specifying that a file is partial (being downloaded). --> Loading src/com/android/documentsui/base/DocumentInfo.java +5 −0 Original line number Diff line number Diff line Loading @@ -229,6 +229,7 @@ public class DocumentInfo implements Durable, Parcelable { + ", isMoveSupported=" + isMoveSupported() + ", isRenameSupported=" + isRenameSupported() + ", isMetadataSupported=" + isMetadataSupported() + ", isBlockedFromTree=" + isBlockedFromTree() + "} @ " + derivedUri; } Loading Loading @@ -289,6 +290,10 @@ public class DocumentInfo implements Durable, Parcelable { return (flags & Document.FLAG_PARTIAL) != 0; } public boolean isBlockedFromTree() { return (flags & Document.FLAG_DIR_BLOCKS_TREE) != 0; } // Containers are documents which can be opened in DocumentsUI as folders. public boolean isContainer() { return isDirectory() || (isArchive() && !isInArchive() && !isPartial()); Loading src/com/android/documentsui/inspector/DebugView.java +1 −0 Original line number Diff line number Diff line Loading @@ -78,6 +78,7 @@ public class DebugView extends TableView implements DebugDisplay { put(R.string.debug_stream_types, "-"); put(R.string.debug_raw_size, NumberFormat.getInstance().format(info.size)); put(R.string.debug_is_archive, info.isArchive()); put(R.string.debug_is_blocked_from_tree, info.isBlockedFromTree()); put(R.string.debug_is_container, info.isContainer()); put(R.string.debug_is_partial, info.isPartial()); put(R.string.debug_is_virtual, info.isVirtual()); Loading src/com/android/documentsui/picker/PickFragment.java +3 −2 Original line number Diff line number Diff line Loading @@ -16,9 +16,9 @@ package com.android.documentsui.picker; import static com.android.documentsui.services.FileOperationService.OPERATION_DELETE; import static com.android.documentsui.services.FileOperationService.OPERATION_COPY; import static com.android.documentsui.services.FileOperationService.OPERATION_COMPRESS; import static com.android.documentsui.services.FileOperationService.OPERATION_COPY; import static com.android.documentsui.services.FileOperationService.OPERATION_DELETE; import static com.android.documentsui.services.FileOperationService.OPERATION_EXTRACT; import static com.android.documentsui.services.FileOperationService.OPERATION_MOVE; import static com.android.documentsui.services.FileOperationService.OPERATION_UNKNOWN; Loading Loading @@ -172,6 +172,7 @@ public class PickFragment extends Fragment { mPick.setText(text); mPick.setWidth(Integer.MAX_VALUE); mCancel.setVisibility(View.GONE); mPick.setEnabled(!mPickTarget.isBlockedFromTree()); break; case State.ACTION_PICK_COPY_DESTINATION: int titleId; Loading Loading
res/values/inspector_strings.xml +2 −0 Original line number Diff line number Diff line Loading @@ -98,6 +98,8 @@ <string name="debug_raw_mimetype" translatable="false">Raw mimetype</string> <!-- String label for developer/debug file details, specifying that a file is an archive. --> <string name="debug_is_archive" translatable="false">Is archive</string> <!-- String label for developer/debug file details, specifying that a directory is blocked from tree. --> <string name="debug_is_blocked_from_tree" translatable="false">Is blocked from tree</string> <!-- String label for developer/debug file details, specifying that a file is a container (like a folder or an archive). --> <string name="debug_is_container" translatable="false">Is container</string> <!-- String label for developer/debug file details, specifying that a file is partial (being downloaded). --> Loading
src/com/android/documentsui/base/DocumentInfo.java +5 −0 Original line number Diff line number Diff line Loading @@ -229,6 +229,7 @@ public class DocumentInfo implements Durable, Parcelable { + ", isMoveSupported=" + isMoveSupported() + ", isRenameSupported=" + isRenameSupported() + ", isMetadataSupported=" + isMetadataSupported() + ", isBlockedFromTree=" + isBlockedFromTree() + "} @ " + derivedUri; } Loading Loading @@ -289,6 +290,10 @@ public class DocumentInfo implements Durable, Parcelable { return (flags & Document.FLAG_PARTIAL) != 0; } public boolean isBlockedFromTree() { return (flags & Document.FLAG_DIR_BLOCKS_TREE) != 0; } // Containers are documents which can be opened in DocumentsUI as folders. public boolean isContainer() { return isDirectory() || (isArchive() && !isInArchive() && !isPartial()); Loading
src/com/android/documentsui/inspector/DebugView.java +1 −0 Original line number Diff line number Diff line Loading @@ -78,6 +78,7 @@ public class DebugView extends TableView implements DebugDisplay { put(R.string.debug_stream_types, "-"); put(R.string.debug_raw_size, NumberFormat.getInstance().format(info.size)); put(R.string.debug_is_archive, info.isArchive()); put(R.string.debug_is_blocked_from_tree, info.isBlockedFromTree()); put(R.string.debug_is_container, info.isContainer()); put(R.string.debug_is_partial, info.isPartial()); put(R.string.debug_is_virtual, info.isVirtual()); Loading
src/com/android/documentsui/picker/PickFragment.java +3 −2 Original line number Diff line number Diff line Loading @@ -16,9 +16,9 @@ package com.android.documentsui.picker; import static com.android.documentsui.services.FileOperationService.OPERATION_DELETE; import static com.android.documentsui.services.FileOperationService.OPERATION_COPY; import static com.android.documentsui.services.FileOperationService.OPERATION_COMPRESS; import static com.android.documentsui.services.FileOperationService.OPERATION_COPY; import static com.android.documentsui.services.FileOperationService.OPERATION_DELETE; import static com.android.documentsui.services.FileOperationService.OPERATION_EXTRACT; import static com.android.documentsui.services.FileOperationService.OPERATION_MOVE; import static com.android.documentsui.services.FileOperationService.OPERATION_UNKNOWN; Loading Loading @@ -172,6 +172,7 @@ public class PickFragment extends Fragment { mPick.setText(text); mPick.setWidth(Integer.MAX_VALUE); mCancel.setVisibility(View.GONE); mPick.setEnabled(!mPickTarget.isBlockedFromTree()); break; case State.ACTION_PICK_COPY_DESTINATION: int titleId; Loading