newest quantum CVS sources
[phpeclipse.git] / archive / net.sourceforge.phpeclipse.quantum.sql / src / com / quantum / view / bookmark / BookmarkViewActionGroup.java
index 09f636b..3af90bd 100644 (file)
@@ -2,7 +2,7 @@ package com.quantum.view.bookmark;
 
 import java.util.Iterator;
 
-import com.quantum.QuantumPlugin;
+import com.quantum.ImageStore;
 import com.quantum.actions.AddToQuickListAction;
 import com.quantum.actions.ConnectAction;
 import com.quantum.actions.DeleteAllRowsAction;
@@ -17,6 +17,7 @@ import com.quantum.actions.RemoveFromQuickListAction;
 import com.quantum.actions.ViewTableAction;
 import com.quantum.actions.ViewTableDetailsAction;
 import com.quantum.model.Bookmark;
+import com.quantum.util.versioning.VersioningHelper;
 
 import org.eclipse.jface.action.Action;
 import org.eclipse.jface.action.IAction;
@@ -103,9 +104,9 @@ public class BookmarkViewActionGroup extends ActionGroup
         this.renameAction = new RenameAction(this.viewPart);
         this.copyAction = new CopyAction(this.viewPart, this, selectionProvider);
         this.pasteAction = new PasteAction(this.viewPart, this, selectionProvider);
-        this.exportAction = new ExportResourcesAction(
-            this.viewPart.getViewSite().getWorkbenchWindow());
-        this.exportAction.setImageDescriptor(QuantumPlugin.getImageDescriptor("export.gif"));
+        this.exportAction = VersioningHelper.createExportResourcesAction(
+                       this.viewPart.getViewSite().getWorkbenchWindow());
+        this.exportAction.setImageDescriptor(ImageStore.getImageDescriptor(ImageStore.EXPORT));
         
         this.propertiesAction = new PropertyDialogAction(
             this.viewPart.getSite().getShell(), selectionProvider);
@@ -144,8 +145,10 @@ public class BookmarkViewActionGroup extends ActionGroup
 
         // NOTE: In Eclipse 3.0.0 M6, Export is no longer a sub-class of 
         //       SelectionListenerAction.
-        this.exportAction.selectionChanged(getStructuredSelection());
-        menu.add(this.exportAction);
+        if (this.exportAction != null) {
+               this.exportAction.selectionChanged(getStructuredSelection());
+               menu.add(this.exportAction);
+        }
 
         if (getStructuredSelection().size() == 1 && 
             isEverySelectionInstanceof(BookmarkNode.class)) {