[
https://issues.apache.org/jira/browse/PIVOT-862?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13415336#comment-13415336
]
Sandro Martini commented on PIVOT-862:
--------------------------------------
Wait a moment ... in Pivot832 (under tests) I see a comment (written by me some
time ago), that could solve this:
fileBrowserSheet.setMode(FileBrowserSheet.Mode.SAVE_TO); // to
be able to select a folder
can you try with this (and tell me what happens in your case) ?
> FileBrowser[Sheet] display the contents of the root instead of actual folder
> in some circumstancies
> ---------------------------------------------------------------------------------------------------
>
> Key: PIVOT-862
> URL: https://issues.apache.org/jira/browse/PIVOT-862
> Project: Pivot
> Issue Type: Bug
> Affects Versions: 2.0.2
> Environment: Windows XP, java 6
> Reporter: Guillaume Deshors
> Assignee: Sandro Martini
> Priority: Minor
> Fix For: 2.0.3
>
> Attachments: bug-862.png
>
>
> When you open a fresh FileBrowser or FileBrowserSheet, with a no-argument
> constructor, and then you set the root directory to a directory under another
> drive than C:, say "T:\FOLDER" for example, then when you open it it seems to
> be located at the right place (from the above bar) but the actual displayed
> files are those at the root of the drive. See screen capture for better
> comprehension.
> Seems to appear when :
> * the root folder is not specified in the constructor
> * the root folder is not under C: (reproduced with network drives and USB
> keys, couldn't try with another partition or internal drive as I don't have
> one here)
> Steps to reproduce :
> 1/ map T: to a network drive or plug in a USB key
> 2/ create the following structure : T:\FOLDER\SUBFOLDER
> 3/ run the following code :
> Window window = new Window();
> window.open(display);
> window.setMaximized(true);
> FileBrowserSheet fileBrowserSheetFile = new
> FileBrowserSheet(Mode.OPEN);
> // The folder structure is T:\FOLDER\SUBFOLDER
> fileBrowserSheetFile.setRootDirectory(new File("T:\\FOLDER\\"));
> fileBrowserSheetFile.open(window);
> // Bug : it actually opens on FOLDER but displayed is the
> content of T: root
> Expected : I want to see my "SUBFOLDER" but I actually see "FOLDER".
> Remark : If I want to set the root to a more deeply nested folder, like
> d:\f1\f2\f3, I still see the content of d:
> Workaround : use the constructor with the root folder in it, like :
> FileBrowserSheet fileBrowserSheetFile = new FileBrowserSheet(Mode.OPEN,
> "T:\\FOLDER");
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira