eclipse - ContainerSelectionDialog in Java -


i develop first plugin - 2 questions:

  1. i'm using containerselectiondialog dialog in eclipse plugin give user option choose project. show me project , folder in them, want show user project out option expend project , choose folder, how can it?

  2. when user select wizard (new->other->mywizard) want know project in packageexplorer select ( have in new class know project selectd)

thanks!!

you can use org.eclipse.ui.dialogs.elementlistselectiondialog , call setelements() on it. data pass setelements() should array of iproject instances; 1 way obtain via org.eclipse.core.resources.resourcesplugin.getworkspace().getroot().getprojects()

note a: iworkspaceroot.getprojects() return projects, including closed ones, depending on needs may want filter list before passing dialog (look @ iproject.isaccessible())

note b: can use org.eclipse.ui.model.workbenchlabelprovider.getdecoratingworkbenchlabelprovider() dialog's labelprovider.


Comments

Popular posts from this blog

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -

php - Controller/JToolBar not working in Joomla 2.5 -