Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 339145

Summary: [client] need a directory prompting dialog
Product: [ECD] Orion Reporter: Susan McCourt <susan>
Component: ClientAssignee: Nayna Jain <jainnayna>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: john.arthorne, malgorzata.tomczyk, mamacdon, Szymon.Brandys, tomasz.zarna
Version: 0.2   
Target Milestone: 0.2   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Bug Depends on:    
Bug Blocks: 339937, 343625, 344227, 345919    

Description Susan McCourt CLA 2011-03-07 16:38:30 EST
There are cases in the UI where we need to prompt for a directory location on the server.  We should have a common dialog for this.  The case I have is:

- file move/copy prompt for a target (for example, if the path you want is not visible so you can't use the menus or a future drag and drop)

But I suspect we might have other needs...
Comment 1 Szymon Brandys CLA 2011-03-07 17:31:31 EST
Another case is to select the Git clone location on the server to link it to the user's workspace.
Comment 2 Mark Macdonald CLA 2011-03-07 17:56:50 EST
I have a use case for this as well: when creating a site configuration, you often want to mount a directory path from your workspace to some location on your virtual host.
Comment 3 Susan McCourt CLA 2011-03-31 13:10:56 EDT
Nayna is looking for some M7 work and this seems like a good, independent task.
Comment 4 Susan McCourt CLA 2011-04-27 11:55:00 EDT
Nayna, it would be good to get this in early in M8 so that consumers have time to adopt it and give feedback before final release.
Comment 5 Szymon Brandys CLA 2011-05-17 11:56:41 EDT
Any news?
Comment 6 Susan McCourt CLA 2011-05-17 14:29:33 EDT
I believe Nayna is planning to release something within a day or so.  Nayna, it would be good to keep us posted here...
Comment 7 Susan McCourt CLA 2011-05-26 18:19:37 EDT
fixed.
The basic functionality is there, we can open new bugs for problems or enhancements.  Bugs can be assigned to Nayna but please cc: me (or just open to the inbox and i'll triage).

For now the dialog opens unexpanded but will remember the expansions afterward.

Sample usage:
var dialog = new widgets.DirectoryPrompterDialog({
	title: "Choose a Folder",
	serviceRegistry: serviceRegistry,
	fileClient: fileClient,				
	func: function(targetFolder) { // targetFolder is the model item
		if (targetFolder && targetFolder.Location) {
			// do your stuff 
		}

	}
});
dialog.startup();
dialog.show();