directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r494218 - in /directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui: actions/ dialogs/ views/browser/ widgets/browser/
Date Mon, 08 Jan 2007 22:08:09 GMT
Author: seelmann
Date: Mon Jan  8 14:08:08 2007
New Revision: 494218

URL: http://svn.apache.org/viewvc?view=rev&rev=494218
Log:
Renamed FilterSubtree to FilterChildren, Javadocs

Added:
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterChildrenAction.java
      - copied, changed from r494201, directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterSubtreeAction.java
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterChildrenAction.java
      - copied, changed from r494201, directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterSubtreeAction.java
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterChildrenDialog.java
      - copied, changed from r494201, directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterSubtreeDialog.java
Removed:
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterSubtreeAction.java
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterSubtreeAction.java
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterSubtreeDialog.java
Modified:
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/views/browser/BrowserViewActionGroup.java
    directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/widgets/browser/BrowserActionGroup.java

Copied: directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterChildrenAction.java
(from r494201, directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterSubtreeAction.java)
URL: http://svn.apache.org/viewvc/directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterChildrenAction.java?view=diff&rev=494218&p1=directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterSubtreeAction.java&r1=494201&p2=directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterChildrenAction.java&r2=494218
==============================================================================
--- directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterSubtreeAction.java
(original)
+++ directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/FilterChildrenAction.java
Mon Jan  8 14:08:08 2007
@@ -25,25 +25,27 @@
 import org.apache.directory.ldapstudio.browser.core.model.IEntry;
 import org.apache.directory.ldapstudio.browser.ui.BrowserUIConstants;
 import org.apache.directory.ldapstudio.browser.ui.BrowserUIPlugin;
-import org.apache.directory.ldapstudio.browser.ui.dialogs.FilterSubtreeDialog;
+import org.apache.directory.ldapstudio.browser.ui.dialogs.FilterChildrenDialog;
 
 import org.eclipse.jface.dialogs.Dialog;
 import org.eclipse.jface.resource.ImageDescriptor;
 
 
 /**
- * TODO DOCUMENT ME! FilterSubtreeAction.
+ * This action opens the Filter Children Dialog and sets the children filter to the
+ * currently selected entry. It is useful when browsing the DIT and entries with 
+ * many child nodes.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class FilterSubtreeAction extends BrowserAction
+public class FilterChildrenAction extends BrowserAction
 {
 
     /**
-     * Creates a new instance of FilterSubtreeAction.
+     * Creates a new instance of FilterChildrenAction.
      */
-    public FilterSubtreeAction()
+    public FilterChildrenAction()
     {
         super();
     }
@@ -56,10 +58,7 @@
     {
         if ( getSelectedEntries().length == 1 )
         {
-            // InputDialog dialog = new
-            // InputDialog(this.part.getSite().getShell(), "Filter", "Enter
-            // filter:", this.selectedEntry.getFilter(), null);
-            FilterSubtreeDialog dialog = new FilterSubtreeDialog( getShell(), getSelectedEntries()[0]
+            FilterChildrenDialog dialog = new FilterChildrenDialog( getShell(), getSelectedEntries()[0]
                 .getChildrenFilter(), getSelectedEntries()[0].getConnection() );
             if ( dialog.open() == Dialog.OK )
             {
@@ -86,7 +85,7 @@
      */
     public String getText()
     {
-        return "Filter Subtree...";
+        return "Filter Children...";
     }
 
 

Copied: directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterChildrenAction.java
(from r494201, directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterSubtreeAction.java)
URL: http://svn.apache.org/viewvc/directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterChildrenAction.java?view=diff&rev=494218&p1=directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterSubtreeAction.java&r1=494201&p2=directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterChildrenAction.java&r2=494218
==============================================================================
--- directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterSubtreeAction.java
(original)
+++ directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/actions/UnfilterChildrenAction.java
Mon Jan  8 14:08:08 2007
@@ -30,17 +30,17 @@
 
 
 /**
- * TODO DOCUMENT ME! UnfilterSubtreeAction.
+ * This action removes the children filter from the currently selected entry.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class UnfilterSubtreeAction extends BrowserAction
+public class UnfilterChildrenAction extends BrowserAction
 {
     /**
-     * Creates a new instance of UnfilterSubtreeAction.
+     * Creates a new instance of UnfilterChildrenAction.
      */
-    public UnfilterSubtreeAction()
+    public UnfilterChildrenAction()
     {
         super();
     }
@@ -65,7 +65,7 @@
      */
     public String getText()
     {
-        return "Remove Subtree Filter";
+        return "Remove Children Filter";
     }
 
 

Copied: directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterChildrenDialog.java
(from r494201, directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterSubtreeDialog.java)
URL: http://svn.apache.org/viewvc/directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterChildrenDialog.java?view=diff&rev=494218&p1=directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterSubtreeDialog.java&r1=494201&p2=directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterChildrenDialog.java&r2=494218
==============================================================================
--- directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterSubtreeDialog.java
(original)
+++ directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/dialogs/FilterChildrenDialog.java
Mon Jan  8 14:08:08 2007
@@ -34,19 +34,37 @@
 import org.eclipse.swt.widgets.Shell;
 
 
-public class FilterSubtreeDialog extends Dialog
+/**
+ * This dialog is used to enter a LDAP filter to filter the child nodes
+ * of an entry.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
+ */
+public class FilterChildrenDialog extends Dialog
 {
 
-    public static final String DIALOG_TITLE = "Filter Subtree";
+    /** The title */
+    public static final String DIALOG_TITLE = "Filter Children";
 
+    /** The connection, used for attribute completion. */
     private IConnection connection;
 
+    /** The filter widget. */
     private FilterWidget filterWidget;
 
+    /** The filter. */
     private String filter;
 
 
-    public FilterSubtreeDialog( Shell parentShell, String filter, IConnection connection
)
+    /**
+     * Creates a new instance of FilterChildrenDialog.
+     *
+     * @param parentShell the parent shell
+     * @param filter the inital filter
+     * @param connection the connection, used for attribute completion
+     */
+    public FilterChildrenDialog( Shell parentShell, String filter, IConnection connection
)
     {
         super( parentShell );
         this.filter = filter;
@@ -55,12 +73,20 @@
     }
 
 
+    /**
+     * Gets the filter.
+     * 
+     * @return the filter
+     */
     public String getFilter()
     {
         return this.filter;
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     protected void configureShell( Shell newShell )
     {
         super.configureShell( newShell );
@@ -68,6 +94,9 @@
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     protected void buttonPressed( int buttonId )
     {
         if ( buttonId == IDialogConstants.OK_ID )
@@ -81,21 +110,14 @@
     }
 
 
-    protected Control createButtonBar( Composite parent )
-    {
-        Composite composite = ( Composite ) super.createButtonBar( parent );
-        return composite;
-    }
-
-
+    /**
+     * {@inheritDoc}
+     */
     protected Control createDialogArea( Composite parent )
     {
-        // Composite composite = parent;
         Composite composite = ( Composite ) super.createDialogArea( parent );
         GridData gd = new GridData( GridData.FILL_BOTH );
         gd.widthHint = convertHorizontalDLUsToPixels( IDialogConstants.MINIMUM_MESSAGE_AREA_WIDTH
);
-        // gd.heightHint =
-        // convertHorizontalDLUsToPixels(IDialogConstants.MINIMUM_MESSAGE_AREA_WIDTH)/2;
         composite.setLayoutData( gd );
 
         Composite inner = new Composite( composite, SWT.NONE );
@@ -107,22 +129,9 @@
 
         filterWidget = new FilterWidget( connection, filter != null ? filter : "" );
         filterWidget.createWidget( inner );
-        // filterWidget.addWidgetModifyListener(new WidgetModifyListener(){
-        // public void widgetModified(WidgetModifyEvent event) {
-        // wizard.setExportFilter(filterWidget.getFilter());
-        // validate();
-        // }
-        // });
         filterWidget.setFocus();
 
         return composite;
-    }
-
-
-    protected boolean canHandleShellCloseEvent()
-    {
-        // proposal popup is opened, don't close dialog!
-        return super.canHandleShellCloseEvent();
     }
 
 }

Modified: directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/views/browser/BrowserViewActionGroup.java
URL: http://svn.apache.org/viewvc/directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/views/browser/BrowserViewActionGroup.java?view=diff&rev=494218&r1=494217&r2=494218
==============================================================================
--- directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/views/browser/BrowserViewActionGroup.java
(original)
+++ directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/views/browser/BrowserViewActionGroup.java
Mon Jan  8 14:08:08 2007
@@ -260,10 +260,10 @@
         menuManager.add( new Separator() );
 
         // filter, batch
-        menuManager.add( ( IAction ) this.browserActionMap.get( filterSubtreeAction ) );
-        if ( ( ( IAction ) this.browserActionMap.get( unfilterSubtreeAction ) ).isEnabled()
)
+        menuManager.add( ( IAction ) this.browserActionMap.get( filterChildrenAction ) );
+        if ( ( ( IAction ) this.browserActionMap.get( unfilterChildrenAction ) ).isEnabled()
)
         {
-            menuManager.add( ( IAction ) this.browserActionMap.get( unfilterSubtreeAction
) );
+            menuManager.add( ( IAction ) this.browserActionMap.get( unfilterChildrenAction
) );
         }
         menuManager.add( new Separator() );
 

Modified: directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/widgets/browser/BrowserActionGroup.java
URL: http://svn.apache.org/viewvc/directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/widgets/browser/BrowserActionGroup.java?view=diff&rev=494218&r1=494217&r2=494218
==============================================================================
--- directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/widgets/browser/BrowserActionGroup.java
(original)
+++ directory/trunks/ldapstudio/ldapstudio-browser-ui/src/main/java/org/apache/directory/ldapstudio/browser/ui/widgets/browser/BrowserActionGroup.java
Mon Jan  8 14:08:08 2007
@@ -27,10 +27,10 @@
 
 import org.apache.directory.ldapstudio.browser.core.model.IConnection;
 import org.apache.directory.ldapstudio.browser.ui.actions.CollapseAllAction;
-import org.apache.directory.ldapstudio.browser.ui.actions.FilterSubtreeAction;
+import org.apache.directory.ldapstudio.browser.ui.actions.FilterChildrenAction;
 import org.apache.directory.ldapstudio.browser.ui.actions.PropertiesAction;
 import org.apache.directory.ldapstudio.browser.ui.actions.RefreshAction;
-import org.apache.directory.ldapstudio.browser.ui.actions.UnfilterSubtreeAction;
+import org.apache.directory.ldapstudio.browser.ui.actions.UnfilterChildrenAction;
 import org.apache.directory.ldapstudio.browser.ui.actions.UpAction;
 import org.apache.directory.ldapstudio.browser.ui.actions.proxy.BrowserViewActionProxy;
 
@@ -58,9 +58,9 @@
 
     protected static final String refreshAction = "refreshAction";
 
-    protected static final String filterSubtreeAction = "filterSubtreeAction";
+    protected static final String filterChildrenAction = "filterChildrenAction";
 
-    protected static final String unfilterSubtreeAction = "unfilterSubtreeAction";
+    protected static final String unfilterChildrenAction = "unfilterChildrenAction";
 
     protected static final String propertyDialogAction = "propertyDialogAction";
 
@@ -83,9 +83,9 @@
         this.browserActionMap.put( upAction, new BrowserViewActionProxy( viewer, new UpAction(
viewer ) ) );
         this.browserActionMap.put( refreshAction, new BrowserViewActionProxy( viewer, new
RefreshAction() ) );
         this.browserActionMap
-            .put( filterSubtreeAction, new BrowserViewActionProxy( viewer, new FilterSubtreeAction()
) );
-        this.browserActionMap.put( unfilterSubtreeAction, new BrowserViewActionProxy( viewer,
-            new UnfilterSubtreeAction() ) );
+            .put( filterChildrenAction, new BrowserViewActionProxy( viewer, new FilterChildrenAction()
) );
+        this.browserActionMap.put( unfilterChildrenAction, new BrowserViewActionProxy( viewer,
+            new UnfilterChildrenAction() ) );
         this.browserActionMap.put( propertyDialogAction, new BrowserViewActionProxy( viewer,
new PropertiesAction() ) );
     }
 
@@ -159,10 +159,10 @@
         menuManager.add( new Separator() );
 
         // filter
-        menuManager.add( ( IAction ) this.browserActionMap.get( filterSubtreeAction ) );
-        if ( ( ( IAction ) this.browserActionMap.get( unfilterSubtreeAction ) ).isEnabled()
)
+        menuManager.add( ( IAction ) this.browserActionMap.get( filterChildrenAction ) );
+        if ( ( ( IAction ) this.browserActionMap.get( unfilterChildrenAction ) ).isEnabled()
)
         {
-            menuManager.add( ( IAction ) this.browserActionMap.get( unfilterSubtreeAction
) );
+            menuManager.add( ( IAction ) this.browserActionMap.get( unfilterChildrenAction
) );
         }
         menuManager.add( new Separator() );
 



Mime
View raw message