+ /*TreeItem currentFolder = getFolders().getCurrent();
+ if (currentFolder != null) {
+ List<FileResource> files = null;
+ Object cachedObject = currentFolder.getUserObject();
+ if (cachedObject instanceof FolderResource) {
+ FolderResource folder = (FolderResource) cachedObject;
+ files = folder.getFiles();
+ } else if (cachedObject instanceof TrashResource) {
+ TrashResource folder = (TrashResource) cachedObject;
+ files = folder.getFiles();
+ }
+ if (files != null)
+ getFileList().setFiles(files);
+ }*/
+ RestResource currentFolder = getTreeView().getSelection();
+ GWT.log("SELECTED:"+currentFolder);
+ if(currentFolder!=null){
+ GWT.log("SELECTED:"+currentFolder.getClass());
+ List<FileResource> files = null;
+ if (currentFolder instanceof RestResourceWrapper) {
+ RestResourceWrapper folder = (RestResourceWrapper) currentFolder;
+ files = folder.getResource().getFiles();
+ } else if (currentFolder instanceof TrashResource) {
+ TrashResource folder = (TrashResource) currentFolder;
+ files = folder.getFiles();
+ }
+ else if(currentFolder instanceof OthersResource){
+ files = new ArrayList<FileResource>();
+ }
+ else if(currentFolder instanceof OtherUserResource){
+ files = ((OtherUserResource)currentFolder).getFiles();
+ }
+ if (files != null)
+ getFileList().setFiles(files);
+ }
+ fileList.updateFileCache(update, true /*clear selection*/);
+ inner.selectTab(0);
+ }
+
+ public void showFileList(RestResource r,boolean update) {
+ /*TreeItem currentFolder = getFolders().getCurrent();