directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pamarce...@apache.org
Subject svn commit: r987577 [6/10] - in /directory/studio/branches/studio-rap/plugins: common.ui/src/main/java/org/apache/directory/studio/common/ui/ connection.ui/src/main/java/org/apache/directory/studio/connection/ui/ connection.ui/src/main/java/org/apache/...
Date Fri, 20 Aug 2010 17:07:23 GMT
Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/entry/LdifEntryEditor.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/entry/LdifEntryEditor.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/entry/LdifEntryEditor.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/entry/LdifEntryEditor.java Fri Aug 20 17:07:19 2010
@@ -46,7 +46,6 @@ import org.eclipse.ui.IEditorSite;
 import org.eclipse.ui.INavigationLocation;
 import org.eclipse.ui.IShowEditorInput;
 import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.texteditor.ITextEditorActionConstants;
 import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
 
 
@@ -153,7 +152,7 @@ public abstract class LdifEntryEditor ex
         super();
 
         // use our own document provider that saves changes to the directory
-        setDocumentProvider( new LdifEntryEditorDocumentProvider( this ) );
+//        setDocumentProvider( new LdifEntryEditorDocumentProvider( this ) );
     }
 
 
@@ -165,19 +164,19 @@ public abstract class LdifEntryEditor ex
 
 
     @Override
-    protected void doSetInput( IEditorInput input ) throws CoreException
-    {
-        super.doSetInput( input );
-
-        IEntry entry = getEntryEditorInput().getResolvedEntry();
-        if ( entry != null )
-        {
-            setConnection( entry.getBrowserConnection() );
-        }
-    }
+//    protected void doSetInput( IEditorInput input ) throws CoreException
+//    {
+//        super.doSetInput( input );
+//
+//        IEntry entry = getEntryEditorInput().getResolvedEntry();
+//        if ( entry != null )
+//        {
+//            setConnection( entry.getBrowserConnection() );
+//        }
+//    }
 
 
-    @Override
+//    @Override
     public void createPartControl( Composite parent )
     {
         // don't show the tool bar
@@ -228,8 +227,8 @@ public abstract class LdifEntryEditor ex
     {
         super.createActions();
 
-        setAction( REFRESH_ACTION, refreshAction );
-        setAction( FETCH_OPERATIONAL_ATTRIBUTES_ACTION, fetchOperationalAttributesAction );
+//        setAction( REFRESH_ACTION, refreshAction );
+//        setAction( FETCH_OPERATIONAL_ATTRIBUTES_ACTION, fetchOperationalAttributesAction );
     }
 
 
@@ -241,8 +240,8 @@ public abstract class LdifEntryEditor ex
         IEntry entry = getEntryEditorInput().getResolvedEntry();
         fetchOperationalAttributesAction.setChecked( ( entry != null ) ? entry.isInitOperationalAttributes() : false );
 
-        addAction( menu, ITextEditorActionConstants.GROUP_REST, REFRESH_ACTION );
-        addAction( menu, ITextEditorActionConstants.GROUP_REST, FETCH_OPERATIONAL_ATTRIBUTES_ACTION );
+//        addAction( menu, ITextEditorActionConstants.GROUP_REST, REFRESH_ACTION );
+//        addAction( menu, ITextEditorActionConstants.GROUP_REST, FETCH_OPERATIONAL_ATTRIBUTES_ACTION );
     }
 
 
@@ -260,18 +259,18 @@ public abstract class LdifEntryEditor ex
     }
 
 
-    @Override
-    public INavigationLocation createNavigationLocation()
-    {
-        return new LdifEntryEditorNavigationLocation( this, true );
-    }
-
-
-    @Override
-    public INavigationLocation createEmptyNavigationLocation()
-    {
-        return new LdifEntryEditorNavigationLocation( this, false );
-    }
+//    @Override
+//    public INavigationLocation createNavigationLocation()
+//    {
+//        return new LdifEntryEditorNavigationLocation( this, true );
+//    }
+//
+//
+//    @Override
+//    public INavigationLocation createEmptyNavigationLocation()
+//    {
+//        return new LdifEntryEditorNavigationLocation( this, false );
+//    }
 
 
     /**
@@ -279,122 +278,122 @@ public abstract class LdifEntryEditor ex
      * 
      * {@inheritDoc}
      */
-    public boolean isAutoSave()
-    {
-        return false;
-    }
-
-
-    /**
-     * This implementation returns always true.
-     * 
-     * {@inheritDoc}
-     */
-    public boolean canHandle( IEntry entry )
-    {
-        return true;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public EntryEditorInput getEntryEditorInput()
-    {
-        return EntryEditorUtils.getEntryEditorInput( getEditorInput() );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public void workingCopyModified( Object source )
-    {
-        ( ( LdifEntryEditorDocumentProvider ) getDocumentProvider() ).workingCopyModified( getEntryEditorInput(),
-            source );
-    }
-
-
-    public void showEditorInput( IEditorInput input )
-    {
-        if ( inShowEditorInput )
-        {
-            /*
-             *  This is to avoid recursion when using history navigation:
-             *  - when selecting an entry this method is called
-             *  - this method fires an input changed event
-             *  - the LinkWithEditorAction gets the event and selects the entry in the browser tree
-             *  - this selection fires an selection event
-             *  - the selection event causes an openEditor() that calls this method again
-             */
-            return;
-        }
-
-        try
-        {
-            inShowEditorInput = true;
-
-            if ( input instanceof EntryEditorInput )
-            {
-                EntryEditorInput eei = ( EntryEditorInput ) input;
-
-                /*
-                 * Optimization: no need to set the input again if the same input is already set
-                 */
-                if ( getEntryEditorInput() != null
-                    && getEntryEditorInput().getResolvedEntry() == eei.getResolvedEntry() )
-                {
-                    return;
-                }
-
-                // If the editor is dirty, let's ask for a save before changing the input
-                if ( isDirty() )
-                {
-                    if ( !EntryEditorUtils.askSaveSharedWorkingCopyBeforeInputChange( this ) )
-                    {
-                        return;
-                    }
-                }
-
-                /*
-                 * Workaround to make link-with-editor working for the single-tab editor:
-                 * The call of firePropertyChange is used to inform the link-with-editor action.
-                 * However firePropertyChange also modifies the navigation history.
-                 * Thus, a dummy input with the real entry but a null extension is set.
-                 * This avoids to modification of the navigation history.
-                 * Afterwards the real input is set.
-                 */
-                IEntry entry = eei.getEntryInput();
-                ISearchResult searchResult = eei.getSearchResultInput();
-                IBookmark bookmark = eei.getBookmarkInput();
-                EntryEditorInput dummyInput;
-                if ( entry != null )
-                {
-                    dummyInput = new EntryEditorInput( entry, null );
-                }
-                else if ( searchResult != null )
-                {
-                    dummyInput = new EntryEditorInput( searchResult, null );
-                }
-                else
-                {
-                    dummyInput = new EntryEditorInput( bookmark, null );
-                }
-                doSetInput( dummyInput );
-                firePropertyChange( IEditorPart.PROP_INPUT );
-
-                // now set the real input and mark history location
-                doSetInput( input );
-                getSite().getPage().getNavigationHistory().markLocation( this );
-            }
-        }
-        catch ( CoreException e )
-        {
-            throw new RuntimeException( e );
-        }
-        finally
-        {
-            inShowEditorInput = false;
-        }
-    }
+//    public boolean isAutoSave()
+//    {
+//        return false;
+//    }
+
+
+//    /**
+//     * This implementation returns always true.
+//     * 
+//     * {@inheritDoc}
+//     */
+//    public boolean canHandle( IEntry entry )
+//    {
+//        return true;
+//    }
+
+
+//    /**
+//     * {@inheritDoc}
+//     */
+//    public EntryEditorInput getEntryEditorInput()
+//    {
+//        return EntryEditorUtils.getEntryEditorInput( getEditorInput() );
+//    }
+
+
+//    /**
+//     * {@inheritDoc}
+//     */
+//    public void workingCopyModified( Object source )
+//    {
+//        ( ( LdifEntryEditorDocumentProvider ) getDocumentProvider() ).workingCopyModified( getEntryEditorInput(),
+//            source );
+//    }
+
+
+//    public void showEditorInput( IEditorInput input )
+//    {
+//        if ( inShowEditorInput )
+//        {
+//            /*
+//             *  This is to avoid recursion when using history navigation:
+//             *  - when selecting an entry this method is called
+//             *  - this method fires an input changed event
+//             *  - the LinkWithEditorAction gets the event and selects the entry in the browser tree
+//             *  - this selection fires an selection event
+//             *  - the selection event causes an openEditor() that calls this method again
+//             */
+//            return;
+//        }
+//
+//        try
+//        {
+//            inShowEditorInput = true;
+//
+//            if ( input instanceof EntryEditorInput )
+//            {
+//                EntryEditorInput eei = ( EntryEditorInput ) input;
+//
+//                /*
+//                 * Optimization: no need to set the input again if the same input is already set
+//                 */
+//                if ( getEntryEditorInput() != null
+//                    && getEntryEditorInput().getResolvedEntry() == eei.getResolvedEntry() )
+//                {
+//                    return;
+//                }
+//
+//                // If the editor is dirty, let's ask for a save before changing the input
+//                if ( isDirty() )
+//                {
+//                    if ( !EntryEditorUtils.askSaveSharedWorkingCopyBeforeInputChange( this ) )
+//                    {
+//                        return;
+//                    }
+//                }
+//
+//                /*
+//                 * Workaround to make link-with-editor working for the single-tab editor:
+//                 * The call of firePropertyChange is used to inform the link-with-editor action.
+//                 * However firePropertyChange also modifies the navigation history.
+//                 * Thus, a dummy input with the real entry but a null extension is set.
+//                 * This avoids to modification of the navigation history.
+//                 * Afterwards the real input is set.
+//                 */
+//                IEntry entry = eei.getEntryInput();
+//                ISearchResult searchResult = eei.getSearchResultInput();
+//                IBookmark bookmark = eei.getBookmarkInput();
+//                EntryEditorInput dummyInput;
+//                if ( entry != null )
+//                {
+//                    dummyInput = new EntryEditorInput( entry, null );
+//                }
+//                else if ( searchResult != null )
+//                {
+//                    dummyInput = new EntryEditorInput( searchResult, null );
+//                }
+//                else
+//                {
+//                    dummyInput = new EntryEditorInput( bookmark, null );
+//                }
+//                doSetInput( dummyInput );
+//                firePropertyChange( IEditorPart.PROP_INPUT );
+//
+//                // now set the real input and mark history location
+//                doSetInput( input );
+//                getSite().getPage().getNavigationHistory().markLocation( this );
+//            }
+//        }
+//        catch ( CoreException e )
+//        {
+//            throw new RuntimeException( e );
+//        }
+//        finally
+//        {
+//            inShowEditorInput = false;
+//        }
+//    }
 }

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaPage.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaPage.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaPage.java Fri Aug 20 17:07:19 2010
@@ -242,7 +242,7 @@ public abstract class SchemaPage
         gd.heightHint = 20;
         gd.widthHint = 100;
         t.setLayoutData( gd );
-        toolkit.paintBordersFor( client );
+//        toolkit.paintBordersFor( client );
 
         // setup viewer
         viewer = new TableViewer( t );

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/AbstractOpenEditorAction.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/AbstractOpenEditorAction.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/AbstractOpenEditorAction.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/AbstractOpenEditorAction.java Fri Aug 20 17:07:19 2010
@@ -103,46 +103,46 @@ public abstract class AbstractOpenEditor
      */
     private void activateEditor()
     {
-        Object element = cursor.getRow().getData();
-        String property = ( String ) viewer.getColumnProperties()[cursor.getColumn()];
+//        Object element = cursor.getRow().getData();
+//        String property = ( String ) viewer.getColumnProperties()[cursor.getColumn()];
 
-        if ( !viewer.isCellEditorActive() && viewer.getCellModifier().canModify( element, property ) )
-        {
-            // disable action handlers
-            actionGroup.deactivateGlobalActionHandlers();
-
-            // set cell editor to viewer
-            for ( int i = 0; i < viewer.getCellEditors().length; i++ )
-            {
-                viewer.getCellEditors()[i] = cellEditor;
-            }
-
-            // add listener for end of editing
-            if ( cellEditor.getControl() != null )
-            {
-                cellEditor.getControl().addFocusListener( this );
-                cellEditor.getControl().addKeyListener( this );
-            }
-
-            // deactivate cursor
-            cursor.setVisible( false );
-
-            // start editing
-            isActive = true;
-            viewer.editElement( element, cursor.getColumn() );
-
-            viewer.setSelection( null, true );
-            viewer.getTable().setSelection( new TableItem[0] );
-
-            if ( !viewer.isCellEditorActive() )
-            {
-                editorClosed();
-            }
-        }
-        else
-        {
-            valueEditorManager.setUserSelectedValueEditor( null );
-        }
+//        if ( !viewer.isCellEditorActive() && viewer.getCellModifier().canModify( element, property ) )
+//        {
+//            // disable action handlers
+//            actionGroup.deactivateGlobalActionHandlers();
+//
+//            // set cell editor to viewer
+//            for ( int i = 0; i < viewer.getCellEditors().length; i++ )
+//            {
+//                viewer.getCellEditors()[i] = cellEditor;
+//            }
+//
+//            // add listener for end of editing
+//            if ( cellEditor.getControl() != null )
+//            {
+//                cellEditor.getControl().addFocusListener( this );
+//                cellEditor.getControl().addKeyListener( this );
+//            }
+//
+//            // deactivate cursor
+//            cursor.setVisible( false );
+//
+//            // start editing
+//            isActive = true;
+//            viewer.editElement( element, cursor.getColumn() );
+//
+//            viewer.setSelection( null, true );
+//            viewer.getTable().setSelection( new TableItem[0] );
+//
+//            if ( !viewer.isCellEditorActive() )
+//            {
+//                editorClosed();
+//            }
+//        }
+//        else
+//        {
+//            valueEditorManager.setUserSelectedValueEditor( null );
+//        }
     }
 
 
@@ -167,16 +167,16 @@ public abstract class AbstractOpenEditor
         valueEditorManager.setUserSelectedValueEditor( null );
 
         // activate cursor
-        cursor.setVisible( true );
-        viewer.refresh();
-        cursor.redraw();
-        cursor.getDisplay().asyncExec( new Runnable()
-        {
-            public void run()
-            {
-                cursor.setFocus();
-            }
-        } );
+//        cursor.setVisible( true );
+//        viewer.refresh();
+//        cursor.redraw();
+//        cursor.getDisplay().asyncExec( new Runnable()
+//        {
+//            public void run()
+//            {
+//                cursor.setFocus();
+//            }
+//        } );
 
         // enable action handlers
         actionGroup.activateGlobalActionHandlers();

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java Fri Aug 20 17:07:19 2010
@@ -99,40 +99,40 @@ public class SearchResultEditor extends 
 
             IEntry modifiedEntry = event.getModifiedEntry();
             IEntry originalEntry = modifiedEntry.getBrowserConnection().getEntryFromCache( modifiedEntry.getDn() );
-            ISearchResult referenceCopy = configuration.getCursor( mainWidget.getViewer() ).getSelectedReferenceCopy();
-            ISearchResult workingCopy = configuration.getCursor( mainWidget.getViewer() ).getSelectedSearchResult();
+//            ISearchResult referenceCopy = configuration.getCursor( mainWidget.getViewer() ).getSelectedReferenceCopy();
+//            ISearchResult workingCopy = configuration.getCursor( mainWidget.getViewer() ).getSelectedSearchResult();
 
-            // check on object identity, nothing should be done for equal objects from other editors
-            if ( workingCopy != null && workingCopy.getEntry() == modifiedEntry )
-            {
-                // only save if we receive a real value modification event
-                if ( !( event instanceof ValueAddedEvent || event instanceof ValueDeletedEvent
-                    || event instanceof ValueModifiedEvent || event instanceof ValueRenamedEvent || event instanceof ValueMultiModificationEvent ) )
-                {
-                    return;
-                }
-                // consistency check: don't save if there is an empty value, silently return in that case
-                for ( IAttribute attribute : modifiedEntry.getAttributes() )
-                {
-                    for ( IValue value : attribute.getValues() )
-                    {
-                        if ( value.isEmpty() )
-                        {
-                            return;
-                        }
-                    }
-                }
-
-                LdifFile diff = Utils.computeDiff( referenceCopy.getEntry(), modifiedEntry );
-                if ( diff != null )
-                {
-                    // save
-                    UpdateEntryRunnable runnable = new UpdateEntryRunnable( originalEntry, diff
-                        .toFormattedString( LdifFormatParameters.DEFAULT ) );
-                    RunnableContextRunner.execute( runnable, null, true );
-                }
-                configuration.getCursor( mainWidget.getViewer() ).resetCopies();
-            }
+//            // check on object identity, nothing should be done for equal objects from other editors
+//            if ( workingCopy != null && workingCopy.getEntry() == modifiedEntry )
+//            {
+//                // only save if we receive a real value modification event
+//                if ( !( event instanceof ValueAddedEvent || event instanceof ValueDeletedEvent
+//                    || event instanceof ValueModifiedEvent || event instanceof ValueRenamedEvent || event instanceof ValueMultiModificationEvent ) )
+//                {
+//                    return;
+//                }
+//                // consistency check: don't save if there is an empty value, silently return in that case
+//                for ( IAttribute attribute : modifiedEntry.getAttributes() )
+//                {
+//                    for ( IValue value : attribute.getValues() )
+//                    {
+//                        if ( value.isEmpty() )
+//                        {
+//                            return;
+//                        }
+//                    }
+//                }
+//
+//                LdifFile diff = Utils.computeDiff( referenceCopy.getEntry(), modifiedEntry );
+//                if ( diff != null )
+//                {
+//                    // save
+//                    UpdateEntryRunnable runnable = new UpdateEntryRunnable( originalEntry, diff
+//                        .toFormattedString( LdifFormatParameters.DEFAULT ) );
+//                    RunnableContextRunner.execute( runnable, null, true );
+//                }
+//                configuration.getCursor( mainWidget.getViewer() ).resetCopies();
+//            }
         }
     };
 
@@ -255,7 +255,7 @@ public class SearchResultEditor extends 
 
         // create the listener
         universalListener = new SearchResultEditorUniversalListener( this );
-        getSite().setSelectionProvider( configuration.getCursor( mainWidget.getViewer() ) );
+//        getSite().setSelectionProvider( configuration.getCursor( mainWidget.getViewer() ) );
         this.setInput( getEditorInput() );
 
         BrowserUIPlugin.getDefault().getPreferenceStore().addPropertyChangeListener( this );
@@ -371,9 +371,9 @@ public class SearchResultEditor extends 
             {
                 public ShowInContext getShowInContext()
                 {
-                    ISelection selection = getConfiguration().getCursor( getMainWidget().getViewer() ).getSelection();
-                    return new ShowInContext( getMainWidget().getViewer().getInput(), selection );
-                }
+//                    ISelection selection = getConfiguration().getCursor( getMainWidget().getViewer() ).getSelection();
+//                    return new ShowInContext( getMainWidget().getViewer().getInput(), selection );
+                return null;}
             };
         }
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCellModifier.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCellModifier.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCellModifier.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCellModifier.java Fri Aug 20 17:07:19 2010
@@ -112,29 +112,29 @@ public class SearchResultEditorCellModif
      */
     public Object getValue( Object element, String property )
     {
-        if ( element != null && element instanceof ISearchResult && property != null )
-        {
-            // perform modifications on the clone
-            ISearchResult result = cursor.getSelectedSearchResult();
-            AttributeHierarchy ah = result.getAttributeWithSubtypes( property );
-
-            if ( !canModify( element, property ) )
-            {
-                return null;
-            }
-
-            if ( ah == null )
-            {
-                ah = new AttributeHierarchy( result.getEntry(), property, new IAttribute[]
-                    { new Attribute( result.getEntry(), property ) } );
-            }
-
-            return valueEditorManager.getCurrentValueEditor( ah ).getRawValue( ah );
-        }
-        else
-        {
+//        if ( element != null && element instanceof ISearchResult && property != null )
+//        {
+//            // perform modifications on the clone
+//            ISearchResult result = cursor.getSelectedSearchResult();
+//            AttributeHierarchy ah = result.getAttributeWithSubtypes( property );
+//
+//            if ( !canModify( element, property ) )
+//            {
+//                return null;
+//            }
+//
+//            if ( ah == null )
+//            {
+//                ah = new AttributeHierarchy( result.getEntry(), property, new IAttribute[]
+//                    { new Attribute( result.getEntry(), property ) } );
+//            }
+//
+//            return valueEditorManager.getCurrentValueEditor( ah ).getRawValue( ah );
+//        }
+//        else
+//        {
             return null;
-        }
+//        }
     }
 
 
@@ -143,39 +143,39 @@ public class SearchResultEditorCellModif
      */
     public void modify( Object element, String property, Object newRawValue )
     {
-        if ( element != null && element instanceof Item )
-        {
-            element = ( ( Item ) element ).getData();
-        }
-
-        if ( element != null && element instanceof ISearchResult && property != null )
-        {
-            // perform modifications on the clone
-            ISearchResult result = cursor.getSelectedSearchResult();
-            AttributeHierarchy ah = result.getAttributeWithSubtypes( property );
-
-            // switch operation:
-            if ( ah == null && newRawValue != null )
-            {
-                new CompoundModification().createValue( result.getEntry(), property, newRawValue );
-            }
-            else if ( ah != null && newRawValue == null )
-            {
-                List<IValue> values = new ArrayList<IValue>();
-                for ( IAttribute attribute : ah.getAttributes() )
-                {
-                    for ( IValue value : attribute.getValues() )
-                    {
-                        values.add( value );
-                    }
-                }
-                new CompoundModification().deleteValues( values );
-            }
-            else if ( ah != null && ah.size() == 1 && ah.getAttribute().getValueSize() == 1 && newRawValue != null )
-            {
-                new CompoundModification().modifyValue( ah.getAttribute().getValues()[0], newRawValue );
-            }
-        }
+//        if ( element != null && element instanceof Item )
+//        {
+//            element = ( ( Item ) element ).getData();
+//        }
+//
+//        if ( element != null && element instanceof ISearchResult && property != null )
+//        {
+//            // perform modifications on the clone
+//            ISearchResult result = cursor.getSelectedSearchResult();
+//            AttributeHierarchy ah = result.getAttributeWithSubtypes( property );
+//
+//            // switch operation:
+//            if ( ah == null && newRawValue != null )
+//            {
+//                new CompoundModification().createValue( result.getEntry(), property, newRawValue );
+//            }
+//            else if ( ah != null && newRawValue == null )
+//            {
+//                List<IValue> values = new ArrayList<IValue>();
+//                for ( IAttribute attribute : ah.getAttributes() )
+//                {
+//                    for ( IValue value : attribute.getValues() )
+//                    {
+//                        values.add( value );
+//                    }
+//                }
+//                new CompoundModification().deleteValues( values );
+//            }
+//            else if ( ah != null && ah.size() == 1 && ah.getAttribute().getValueSize() == 1 && newRawValue != null )
+//            {
+//                new CompoundModification().modifyValue( ah.getAttribute().getValues()[0], newRawValue );
+//            }
+//        }
     }
 
 }

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorConfiguration.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorConfiguration.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorConfiguration.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorConfiguration.java Fri Aug 20 17:07:19 2010
@@ -105,8 +105,8 @@ public class SearchResultEditorConfigura
             }
             if ( cursor != null )
             {
-                cursor.dispose();
-                cursor = null;
+//                cursor.dispose();
+//                cursor = null;
             }
             disposed = true;
         }
@@ -156,7 +156,7 @@ public class SearchResultEditorConfigura
         {
             contextMenuManager = new MenuManager();
             Menu menu = contextMenuManager.createContextMenu( viewer.getControl() );
-            getCursor( viewer ).setMenu( menu );
+//            getCursor( viewer ).setMenu( menu );
         }
         return contextMenuManager;
     }
@@ -222,10 +222,10 @@ public class SearchResultEditorConfigura
      */
     public SearchResultEditorCursor getCursor( TableViewer viewer )
     {
-        if ( cursor == null )
-        {
-            cursor = new SearchResultEditorCursor( viewer );
-        }
+//        if ( cursor == null )
+//        {
+//            cursor = new SearchResultEditorCursor( viewer );
+//        }
         return cursor;
     }
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCursor.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCursor.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCursor.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorCursor.java Fri Aug 20 17:07:19 2010
@@ -20,35 +20,11 @@
 
 package org.apache.directory.studio.ldapbrowser.ui.editors.searchresult;
 
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.apache.directory.studio.ldapbrowser.common.BrowserCommonActivator;
-import org.apache.directory.studio.ldapbrowser.core.events.EntryModificationEvent;
-import org.apache.directory.studio.ldapbrowser.core.events.EntryUpdateListener;
-import org.apache.directory.studio.ldapbrowser.core.events.EventRegistry;
-import org.apache.directory.studio.ldapbrowser.core.model.AttributeHierarchy;
-import org.apache.directory.studio.ldapbrowser.core.model.IAttribute;
-import org.apache.directory.studio.ldapbrowser.core.model.IEntry;
-import org.apache.directory.studio.ldapbrowser.core.model.ISearchResult;
-import org.apache.directory.studio.ldapbrowser.core.model.impl.Attribute;
-import org.apache.directory.studio.ldapbrowser.core.model.impl.SearchResult;
-import org.apache.directory.studio.ldapbrowser.core.utils.CompoundModification;
-import org.apache.directory.studio.ldapbrowser.ui.BrowserUIConstants;
 import org.eclipse.jface.viewers.ISelection;
 import org.eclipse.jface.viewers.ISelectionChangedListener;
 import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.TableCursor;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.widgets.Display;
+
+
 
 
 /**
@@ -56,282 +32,26 @@ import org.eclipse.swt.widgets.Display;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class SearchResultEditorCursor extends TableCursor implements ISelectionProvider, EntryUpdateListener
-{
-
-    /** The viewer. */
-    private TableViewer viewer;
-
-    /** The selection changes listener list. */
-    private List<ISelectionChangedListener> selectionChangesListenerList;
-
-    /** The cloned reference copy of the search result under the cursor */
-    private ISearchResult referenceCopy;
-
-    /** The cloned working copy of the search result under the cursor */
-    private ISearchResult workingCopy;
-
-
-    /**
-     * Creates a new instance of SearchResultEditorCursor.
-     * 
-     * @param viewer the viewer
-     */
-    public SearchResultEditorCursor( TableViewer viewer )
-    {
-        super( viewer.getTable(), SWT.NONE );
-        this.viewer = viewer;
-        this.selectionChangesListenerList = new ArrayList<ISelectionChangedListener>();
-
-        setBackground( Display.getDefault().getSystemColor( SWT.COLOR_LIST_SELECTION ) );
-        setForeground( Display.getDefault().getSystemColor( SWT.COLOR_LIST_SELECTION_TEXT ) );
-
-        EventRegistry.addEntryUpdateListener( this, BrowserCommonActivator.getDefault().getEventRunner() );
-
-        initSelectionChecker();
-        initSelectionProvider();
-    }
-
-
-    /**
-     * Initializes the selection checker.
-     */
-    private void initSelectionChecker()
-    {
-        addSelectionListener( new SelectionListener()
-        {
-            public void widgetSelected( SelectionEvent e )
-            {
-                checkSelection();
-            }
-
-
-            public void widgetDefaultSelected( SelectionEvent e )
-            {
-                checkSelection();
-            }
-
-
-            private void checkSelection()
-            {
-                if ( viewer != null && viewer.getColumnProperties() != null
-                    && viewer.getColumnProperties().length - 1 < getColumn() )
-                {
-                    setSelection( getRow(), viewer.getColumnProperties().length - 1 );
-                }
-            }
-        } );
-    }
-
-
-    /**
-     * Initializes the selection provider.
-     */
-    private void initSelectionProvider()
-    {
-        addSelectionListener( new SelectionAdapter()
-        {
-            public void widgetSelected( SelectionEvent e )
-            {
-                for ( Iterator<?> it = selectionChangesListenerList.iterator(); it.hasNext(); )
-                {
-                    ( ( ISelectionChangedListener ) it.next() ).selectionChanged( new SelectionChangedEvent(
-                        SearchResultEditorCursor.this, getSelection() ) );
-                }
-            }
-        } );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public boolean setFocus()
-    {
-        return super.setFocus();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public void dispose()
-    {
-        EventRegistry.removeEntryUpdateListener( this );
-        viewer = null;
-        super.dispose();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public void entryUpdated( EntryModificationEvent event )
-    {
-        viewer.refresh();
-        redraw();
-    }
-
-
-    /**
-     * Gets the selected property.
-     * 
-     * @return the selected property
-     */
-    public String getSelectedProperty()
-    {
-        if ( !isDisposed() && getRow() != null && viewer != null && viewer.getColumnProperties() != null
-            && viewer.getColumnProperties().length >= getColumn() + 1 )
-        {
-            String property = ( String ) viewer.getColumnProperties()[getColumn()];
-            return property;
-        }
-        return null;
-    }
-
-
-    /**
-     * Gets the selected attribute hierarchy.
-     * 
-     * @return the selected attribute hierarchy
-     */
-    public AttributeHierarchy getSelectedAttributeHierarchy()
-    {
-        if ( !isDisposed() && getRow() != null && viewer != null && viewer.getColumnProperties() != null
-            && viewer.getColumnProperties().length >= getColumn() + 1 )
-        {
-            ISearchResult sr = getSelectedSearchResult();
-            String property = ( String ) viewer.getColumnProperties()[getColumn()];
-            if ( sr != null && !BrowserUIConstants.DN.equals( property ) )
-            {
-                AttributeHierarchy ah = sr.getAttributeWithSubtypes( property );
-
-                if ( ah == null )
-                {
-                    ah = new AttributeHierarchy( sr.getEntry(), property, new IAttribute[]
-                        { new Attribute( sr.getEntry(), property ) } );
-                }
-
-                return ah;
-            }
-        }
-        return null;
-    }
-
-
-    /**
-     * Gets the selected search result.
-     * 
-     * @return the selected search result
-     */
-    public ISearchResult getSelectedSearchResult()
-    {
-        if ( !isDisposed() && getRow() != null )
-        {
-            Object o = getRow().getData();
-            if ( o instanceof ISearchResult )
-            {
-                ISearchResult sr = ( ISearchResult ) o;
-                if ( !sr.equals( workingCopy ) )
-                {
-                    IEntry entry = sr.getEntry();
-                    IEntry referenceEntry = new CompoundModification().cloneEntry( entry );
-                    referenceCopy = new SearchResult( referenceEntry, sr.getSearch() );
-                    IEntry workingEntry = new CompoundModification().cloneEntry( entry );
-                    workingCopy = new SearchResult( workingEntry, sr.getSearch() );
-                }
-
-                return workingCopy;
-            }
-        }
-        return null;
-    }
-
-
-    /**
-     * Gets the selected reference copy.
-     * 
-     * @return the selected reference copy, may be null
-     */
-    public ISearchResult getSelectedReferenceCopy()
-    {
-        return referenceCopy;
-    }
-
-
-    /**
-     * Resets reference and working copy copy.
-     */
-    public void resetCopies()
-    {
-        referenceCopy = null;
-        workingCopy = null;
-
-        // update all actions with the fresh selection
-        for ( Iterator<?> it = selectionChangesListenerList.iterator(); it.hasNext(); )
-        {
-            ( ( ISelectionChangedListener ) it.next() ).selectionChanged( new SelectionChangedEvent(
-                SearchResultEditorCursor.this, getSelection() ) );
-        }
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public void addSelectionChangedListener( ISelectionChangedListener listener )
-    {
-        if ( !selectionChangesListenerList.contains( listener ) )
-        {
-            selectionChangesListenerList.add( listener );
-        }
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public ISelection getSelection()
-    {
-        ISearchResult searchResult = getSelectedSearchResult();
-        AttributeHierarchy ah = getSelectedAttributeHierarchy();
-        String property = getSelectedProperty();
-
-        List<Object> list = new ArrayList<Object>();
-        if ( searchResult != null )
-        {
-            list.add( searchResult );
-        }
-        if ( ah != null )
-        {
-            list.add( ah );
-        }
-        if ( property != null )
-        {
-            list.add( property );
-        }
-
-        return new StructuredSelection( list );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public void removeSelectionChangedListener( ISelectionChangedListener listener )
-    {
-        if ( selectionChangesListenerList.contains( listener ) )
-        {
-            selectionChangesListenerList.remove( listener );
-        }
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    public void setSelection( ISelection selection )
-    {
-    }
+public class SearchResultEditorCursor implements ISelectionProvider{
 
+	public void addSelectionChangedListener(ISelectionChangedListener listener) {
+		// TODO Auto-generated method stub
+		
+	}
+
+	public ISelection getSelection() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	public void removeSelectionChangedListener(
+			ISelectionChangedListener listener) {
+		// TODO Auto-generated method stub
+		
+	}
+
+	public void setSelection(ISelection selection) {
+		// TODO Auto-generated method stub
+		
+	}
 }

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorUniversalListener.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorUniversalListener.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorUniversalListener.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorUniversalListener.java Fri Aug 20 17:07:19 2010
@@ -297,15 +297,15 @@ public class SearchResultEditorUniversal
          */
         public void mouseMove( MouseEvent e )
         {
-            if ( !cursor.isDisposed() )
-            {
-                TableItem item = cursor.getRow();
-                if ( cursor.getColumn() == 0
-                    && "DN".equalsIgnoreCase( cursor.getRow().getParent().getColumns()[0].getText() ) ) //$NON-NLS-1$
-                {
-                    checkDnLink( item );
-                }
-            }
+//            if ( !cursor.isDisposed() )
+//            {
+//                TableItem item = cursor.getRow();
+//                if ( cursor.getColumn() == 0
+//                    && "DN".equalsIgnoreCase( cursor.getRow().getParent().getColumns()[0].getText() ) ) //$NON-NLS-1$
+//                {
+//                    checkDnLink( item );
+//                }
+//            }
         }
     };
 
@@ -347,16 +347,16 @@ public class SearchResultEditorUniversal
             viewer.setSelection( null, true );
             viewer.getTable().setSelection( new TableItem[0] );
 
-            ISearchResult result = cursor.getSelectedSearchResult();
-            String property = cursor.getSelectedProperty();
-            if ( property != null && result != null && viewer.getCellModifier().canModify( result, property ) )
-            {
-                cursor.setBackground( Display.getDefault().getSystemColor( SWT.COLOR_LIST_SELECTION ) );
-            }
-            else
-            {
-                cursor.setBackground( Display.getDefault().getSystemColor( SWT.COLOR_TITLE_INACTIVE_FOREGROUND ) );
-            }
+//            ISearchResult result = cursor.getSelectedSearchResult();
+//            String property = cursor.getSelectedProperty();
+//            if ( property != null && result != null && viewer.getCellModifier().canModify( result, property ) )
+//            {
+//                cursor.setBackground( Display.getDefault().getSystemColor( SWT.COLOR_LIST_SELECTION ) );
+//            }
+//            else
+//            {
+//                cursor.setBackground( Display.getDefault().getSystemColor( SWT.COLOR_TITLE_INACTIVE_FOREGROUND ) );
+//            }
 
             // cursor.setForeground(Display.getDefault().getSystemColor(SWT.COLOR_LIST_SELECTION_TEXT));
         }
@@ -428,12 +428,12 @@ public class SearchResultEditorUniversal
                     && startEditAction.getBestValueEditor().getCellEditor() instanceof TextCellEditor )
                 {
                     startEditAction.run();
-                    CellEditor editor = viewer.getCellEditors()[cursor.getColumn()];
-                    if ( editor instanceof TextCellEditor )
-                    {
-                        editor.setValue( String.valueOf( e.character ) );
-                        ( ( Text ) editor.getControl() ).setSelection( 1 );
-                    }
+//                    CellEditor editor = viewer.getCellEditors()[cursor.getColumn()];
+//                    if ( editor instanceof TextCellEditor )
+//                    {
+//                        editor.setValue( String.valueOf( e.character ) );
+//                        ( ( Text ) editor.getControl() ).setSelection( 1 );
+//                    }
                 }
 
             }
@@ -475,14 +475,14 @@ public class SearchResultEditorUniversal
 
         // init listeners
         dnLink.addHyperlinkListener( dnHyperlinkListener );
-        dnLink.addMouseTrackListener( dnMouseTrackListener );
-
-        cursor.addMouseMoveListener( cursorMouseMoveListener );
-        cursor.addSelectionListener( cursorSelectionListener );
-        cursor.addMouseListener( cursorMouseListener );
-        cursor.addKeyListener( cursorKeyListener );
-
-        viewer.getTable().addMouseMoveListener( viewerMouseMoveListener );
+//        dnLink.addMouseTrackListener( dnMouseTrackListener );
+//
+//        cursor.addMouseMoveListener( cursorMouseMoveListener );
+//        cursor.addSelectionListener( cursorSelectionListener );
+//        cursor.addMouseListener( cursorMouseListener );
+//        cursor.addKeyListener( cursorKeyListener );
+//
+//        viewer.getTable().addMouseMoveListener( viewerMouseMoveListener );
 
         editor.getSite().getPage().addPartListener( partListener );
         editor.getSite().getWorkbenchWindow().getSelectionService().addPostSelectionListener( BrowserView.getId(),
@@ -542,21 +542,21 @@ public class SearchResultEditorUniversal
         {
             EmptyValueAddedEvent evae = ( EmptyValueAddedEvent ) event;
             IAttribute att = evae.getAddedValue().getAttribute();
-            AttributeHierarchy ah = cursor.getSelectedAttributeHierarchy();
-            if ( ah != null && ah.contains( att ) )
-            {
-                viewer.setSelection( null, true );
-                viewer.getTable().setSelection( new TableItem[0] );
-                if ( startEditAction.isEnabled() )
-                {
-                    startEditAction.run();
-                }
-            }
+//            AttributeHierarchy ah = cursor.getSelectedAttributeHierarchy();
+//            if ( ah != null && ah.contains( att ) )
+//            {
+//                viewer.setSelection( null, true );
+//                viewer.getTable().setSelection( new TableItem[0] );
+//                if ( startEditAction.isEnabled() )
+//                {
+//                    startEditAction.run();
+//                }
+//            }
         }
         else
         {
-            viewer.refresh( true );
-            cursor.notifyListeners( SWT.Selection, new Event() );
+//            viewer.refresh( true );
+//            cursor.notifyListeners( SWT.Selection, new Event() );
         }
     }
 
@@ -700,7 +700,7 @@ public class SearchResultEditorUniversal
     private void checkDnLink( TableItem item )
     {
         if ( dnLink == null || dnLink.isDisposed() || tableEditor == null || viewer.getTable().isDisposed()
-            || cursor.isDisposed() )
+             )
         {
             return;
         }

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorWidget.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorWidget.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorWidget.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditorWidget.java Fri Aug 20 17:07:19 2010
@@ -77,7 +77,7 @@ public class SearchResultEditorWidget ex
         quickFilterWidget.createComposite( parent );
 
         // create table widget and viewer
-        table = new Table( parent, SWT.BORDER | SWT.HIDE_SELECTION | SWT.VIRTUAL );
+        table = new Table( parent, SWT.BORDER  | SWT.VIRTUAL );
         table.setHeaderVisible( true );
         table.setLinesVisible( true );
         table.setLayoutData( new GridData( GridData.FILL_BOTH ) );
@@ -111,7 +111,7 @@ public class SearchResultEditorWidget ex
      */
     public void setFocus()
     {
-        configuration.getCursor( viewer ).setFocus();
+        configuration.getCursor( viewer );
     }
 
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/ShowQuickFilterAction.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/ShowQuickFilterAction.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/ShowQuickFilterAction.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/ShowQuickFilterAction.java Fri Aug 20 17:07:19 2010
@@ -25,7 +25,6 @@ import org.apache.directory.studio.ldapb
 import org.apache.directory.studio.ldapbrowser.common.BrowserCommonConstants;
 import org.apache.directory.studio.ldapbrowser.ui.BrowserUIPlugin;
 import org.eclipse.jface.action.Action;
-import org.eclipse.ui.texteditor.IWorkbenchActionDefinitionIds;
 
 
 public class ShowQuickFilterAction extends Action
@@ -45,7 +44,7 @@ public class ShowQuickFilterAction exten
         super.setToolTipText( Messages.getString( "ShowQuickFilterAction.ShowQuickFilterToolTip" ) ); //$NON-NLS-1$
         super.setImageDescriptor( BrowserCommonActivator.getDefault().getImageDescriptor(
             BrowserCommonConstants.IMG_FILTER ) );
-        super.setActionDefinitionId( IWorkbenchActionDefinitionIds.FIND_REPLACE );
+        super.setActionDefinitionId( "findreplace" );
         super.setEnabled( true );
 
         this.quickFilterWidget = quickFilterWidget;

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/search/SearchPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/search/SearchPage.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/search/SearchPage.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/search/SearchPage.java Fri Aug 20 17:07:19 2010
@@ -22,7 +22,6 @@ package org.apache.directory.studio.ldap
 
 
 import org.apache.directory.studio.common.ui.widgets.BaseWidgetUtils;
-import org.apache.directory.studio.ldapbrowser.common.actions.BrowserSelectionUtils;
 import org.apache.directory.studio.ldapbrowser.common.widgets.WidgetModifyEvent;
 import org.apache.directory.studio.ldapbrowser.common.widgets.WidgetModifyListener;
 import org.apache.directory.studio.ldapbrowser.common.widgets.search.SearchPageWrapper;
@@ -31,8 +30,6 @@ import org.apache.directory.studio.ldapb
 import org.eclipse.jface.dialogs.DialogPage;
 import org.eclipse.jface.dialogs.IDialogConstants;
 import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.search.ui.ISearchPage;
-import org.eclipse.search.ui.ISearchPageContainer;
 import org.eclipse.swt.layout.GridData;
 import org.eclipse.swt.layout.GridLayout;
 import org.eclipse.swt.widgets.Composite;
@@ -46,11 +43,11 @@ import org.eclipse.ui.PlatformUI;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class SearchPage extends DialogPage implements ISearchPage, WidgetModifyListener
+public class SearchPage extends DialogPage implements WidgetModifyListener
 {
 
     /** The search page container. */
-    private ISearchPageContainer container;
+//    private ISearchPageContainer container;
 
     /** The search. */
     private ISearch search;
@@ -130,13 +127,13 @@ public class SearchPage extends DialogPa
     }
 
 
-    /**
-     * {@inheritDoc}
-     */
-    public void setContainer( ISearchPageContainer container )
-    {
-        this.container = container;
-    }
+//    /**
+//     * {@inheritDoc}
+//     */
+//    public void setContainer( ISearchPageContainer container )
+//    {
+//        this.container = container;
+//    }
 
 
     /**
@@ -145,7 +142,7 @@ public class SearchPage extends DialogPa
     public void createControl( Composite parent )
     {
         // declare search
-        search = BrowserSelectionUtils.getExampleSearch( container.getSelection() );
+//        search = BrowserSelectionUtils.getExampleSearch( container.getSelection() );
 
         // create search page content
         GridLayout gl = new GridLayout();
@@ -178,7 +175,7 @@ public class SearchPage extends DialogPa
      */
     public void setVisible( boolean visible )
     {
-        container.setPerformActionEnabled( spw.isValid() );
+//        container.setPerformActionEnabled( spw.isValid() );
         super.setVisible( visible );
     }
 
@@ -188,7 +185,7 @@ public class SearchPage extends DialogPa
      */
     public void widgetModified( WidgetModifyEvent event )
     {
-        container.setPerformActionEnabled( spw.isValid() );
+//        container.setPerformActionEnabled( spw.isValid() );
 
         setErrorMessage( spw.getErrorMessage() );
         errorMessageLabel.setText( getErrorMessage() != null ? getErrorMessage() : "" ); //$NON-NLS-1$

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsView.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsView.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsView.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsView.java Fri Aug 20 17:07:19 2010
@@ -75,7 +75,7 @@ public class ModificationLogsView extend
      */
     public void setFocus()
     {
-        mainWidget.getSourceViewer().getTextWidget().setFocus();
+//        mainWidget.getSourceViewer().getTextWidget().setFocus();
     }
 
 
@@ -112,7 +112,7 @@ public class ModificationLogsView extend
         // create main widget
         mainWidget = new LdifEditorWidget( null, "", false ); //$NON-NLS-1$
         mainWidget.createWidget( composite );
-        mainWidget.getSourceViewer().setEditable( false );
+//        mainWidget.getSourceViewer().setEditable( false );
 
         // create actions and context menu (and register global actions)
         actionGroup = new ModificationLogsViewActionGroup( this );
@@ -123,8 +123,8 @@ public class ModificationLogsView extend
         universalListener = new ModificationLogsViewUniversalListener( this );
 
         // set help context
-        PlatformUI.getWorkbench().getHelpSystem().setHelp( mainWidget.getSourceViewer().getTextWidget(),
-            BrowserUIConstants.PLUGIN_ID + "." + "tools_modification_logs_view" ); //$NON-NLS-1$ //$NON-NLS-2$
+//        PlatformUI.getWorkbench().getHelpSystem().setHelp( mainWidget.getSourceViewer().getTextWidget(),
+//            BrowserUIConstants.PLUGIN_ID + "." + "tools_modification_logs_view" ); //$NON-NLS-1$ //$NON-NLS-2$
     }
 
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewActionGroup.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewActionGroup.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewActionGroup.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewActionGroup.java Fri Aug 20 17:07:19 2010
@@ -21,7 +21,6 @@
 package org.apache.directory.studio.ldapbrowser.ui.views.modificationlogs;
 
 
-import java.util.HashMap;
 import java.util.Map;
 
 import org.apache.directory.studio.connection.core.ConnectionCoreConstants;
@@ -31,7 +30,6 @@ import org.apache.directory.studio.ldapb
 import org.eclipse.jface.action.IMenuListener;
 import org.eclipse.jface.action.IMenuManager;
 import org.eclipse.jface.action.Separator;
-import org.eclipse.jface.text.source.SourceViewer;
 import org.eclipse.ui.IActionBars;
 
 
@@ -79,21 +77,21 @@ public class ModificationLogsViewActionG
     public ModificationLogsViewActionGroup( ModificationLogsView view )
     {
         this.view = view;
-        SourceViewer viewer = this.view.getMainWidget().getSourceViewer();
+//        SourceViewer viewer = this.view.getMainWidget().getSourceViewer();
 
-        modificationLogsViewActionMap = new HashMap<String, ModificationLogsViewActionProxy>();
-        modificationLogsViewActionMap.put( olderAction, new ModificationLogsViewActionProxy( viewer, new OlderAction(
-            view ) ) );
-        modificationLogsViewActionMap.put( newerAction, new ModificationLogsViewActionProxy( viewer, new NewerAction(
-            view ) ) );
-        modificationLogsViewActionMap.put( refreshAction, new ModificationLogsViewActionProxy( viewer,
-            new RefreshAction( view ) ) );
-        modificationLogsViewActionMap.put( clearAction, new ModificationLogsViewActionProxy( viewer, new ClearAction(
-            view ) ) );
-        modificationLogsViewActionMap.put( exportAction, new ModificationLogsViewActionProxy( viewer,
-            new ExportAction() ) );
-        enableModificationLogsAction = new EnableModificationLogsAction();
-        openModificationLogsPreferencePageAction = new OpenModificationLogsPreferencePageAction();
+//        modificationLogsViewActionMap = new HashMap<String, ModificationLogsViewActionProxy>();
+//        modificationLogsViewActionMap.put( olderAction, new ModificationLogsViewActionProxy( viewer, new OlderAction(
+//            view ) ) );
+//        modificationLogsViewActionMap.put( newerAction, new ModificationLogsViewActionProxy( viewer, new NewerAction(
+//            view ) ) );
+//        modificationLogsViewActionMap.put( refreshAction, new ModificationLogsViewActionProxy( viewer,
+//            new RefreshAction( view ) ) );
+//        modificationLogsViewActionMap.put( clearAction, new ModificationLogsViewActionProxy( viewer, new ClearAction(
+//            view ) ) );
+//        modificationLogsViewActionMap.put( exportAction, new ModificationLogsViewActionProxy( viewer,
+//            new ExportAction() ) );
+//        enableModificationLogsAction = new EnableModificationLogsAction();
+//        openModificationLogsPreferencePageAction = new OpenModificationLogsPreferencePageAction();
     }
 
 
@@ -102,21 +100,21 @@ public class ModificationLogsViewActionG
      */
     public void dispose()
     {
-        if ( view != null )
-        {
-            for ( ModificationLogsViewActionProxy action : modificationLogsViewActionMap.values() )
-            {
-                action.dispose();
-                action = null;
-            }
-            modificationLogsViewActionMap.clear();
-            modificationLogsViewActionMap = null;
-
-            enableModificationLogsAction = null;
-            openModificationLogsPreferencePageAction = null;
-
-            view = null;
-        }
+//        if ( view != null )
+//        {
+//            for ( ModificationLogsViewActionProxy action : modificationLogsViewActionMap.values() )
+//            {
+//                action.dispose();
+//                action = null;
+//            }
+//            modificationLogsViewActionMap.clear();
+//            modificationLogsViewActionMap = null;
+//
+//            enableModificationLogsAction = null;
+//            openModificationLogsPreferencePageAction = null;
+//
+//            view = null;
+//        }
     }
 
 
@@ -127,27 +125,27 @@ public class ModificationLogsViewActionG
      */
     public void fillActionBars( IActionBars actionBars )
     {
-        // Tool Bar
-        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( clearAction ) );
-        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( refreshAction ) );
-        actionBars.getToolBarManager().add( new Separator() );
-        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( olderAction ) );
-        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( newerAction ) );
-        actionBars.getToolBarManager().add( new Separator() );
-        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( exportAction ) );
-
-        // Menu Bar
-        actionBars.getMenuManager().add( enableModificationLogsAction );
-        actionBars.getMenuManager().add( new Separator() );
-        actionBars.getMenuManager().add( openModificationLogsPreferencePageAction );
-        actionBars.getMenuManager().addMenuListener( new IMenuListener()
-        {
-            public void menuAboutToShow( IMenuManager manager )
-            {
-                enableModificationLogsAction.setChecked( ConnectionCorePlugin.getDefault().getPluginPreferences()
-                    .getBoolean( ConnectionCoreConstants.PREFERENCE_MODIFICATIONLOGS_ENABLE ) );
-            }
-        } );
+//        // Tool Bar
+//        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( clearAction ) );
+//        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( refreshAction ) );
+//        actionBars.getToolBarManager().add( new Separator() );
+//        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( olderAction ) );
+//        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( newerAction ) );
+//        actionBars.getToolBarManager().add( new Separator() );
+//        actionBars.getToolBarManager().add( modificationLogsViewActionMap.get( exportAction ) );
+//
+//        // Menu Bar
+//        actionBars.getMenuManager().add( enableModificationLogsAction );
+//        actionBars.getMenuManager().add( new Separator() );
+//        actionBars.getMenuManager().add( openModificationLogsPreferencePageAction );
+//        actionBars.getMenuManager().addMenuListener( new IMenuListener()
+//        {
+//            public void menuAboutToShow( IMenuManager manager )
+//            {
+//                enableModificationLogsAction.setChecked( ConnectionCorePlugin.getDefault().getPluginPreferences()
+//                    .getBoolean( ConnectionCoreConstants.PREFERENCE_MODIFICATIONLOGS_ENABLE ) );
+//            }
+//        } );
     }
 
 
@@ -166,10 +164,10 @@ public class ModificationLogsViewActionG
      */
     public void setInput( ModificationLogsViewInput input )
     {
-        for ( ModificationLogsViewActionProxy action : modificationLogsViewActionMap.values() )
-        {
-            action.inputChanged( input );
-        }
+//        for ( ModificationLogsViewActionProxy action : modificationLogsViewActionMap.values() )
+//        {
+//            action.inputChanged( input );
+//        }
     }
 
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewUniversalListener.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewUniversalListener.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewUniversalListener.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/ModificationLogsViewUniversalListener.java Fri Aug 20 17:07:19 2010
@@ -169,7 +169,7 @@ public class ModificationLogsViewUnivers
                 }
 
                 // change input
-                view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
+//                view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
                 view.getActionGroup().setInput( input );
             }
         }
@@ -196,7 +196,7 @@ public class ModificationLogsViewUnivers
      */
     public void scrollToOldest()
     {
-        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
+//        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
     }
 
 
@@ -205,18 +205,18 @@ public class ModificationLogsViewUnivers
      */
     public void scrollToNewest()
     {
-        try
-        {
-            LdifContainer record = view.getMainWidget().getLdifModel().getLastContainer();
-            int offset = record.getOffset();
-            int line = view.getMainWidget().getSourceViewer().getDocument().getLineOfOffset( offset );
-            if ( line > 3 )
-                line -= 3;
-            view.getMainWidget().getSourceViewer().setTopIndex( line );
-        }
-        catch ( Exception e )
-        {
-        }
+//        try
+//        {
+//            LdifContainer record = view.getMainWidget().getLdifModel().getLastContainer();
+//            int offset = record.getOffset();
+//            int line = view.getMainWidget().getSourceViewer().getDocument().getLineOfOffset( offset );
+//            if ( line > 3 )
+//                line -= 3;
+//            view.getMainWidget().getSourceViewer().setTopIndex( line );
+//        }
+//        catch ( Exception e )
+//        {
+//        }
     }
 
 
@@ -248,8 +248,8 @@ public class ModificationLogsViewUnivers
                     sb.append( e.getMessage() );
                 }
             }
-            view.getMainWidget().getSourceViewer().setTopIndex( 0 );
-            view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
+//            view.getMainWidget().getSourceViewer().setTopIndex( 0 );
+//            view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
         }
     }
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/NewerAction.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/NewerAction.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/NewerAction.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/modificationlogs/NewerAction.java Fri Aug 20 17:07:19 2010
@@ -71,7 +71,7 @@ public class NewerAction extends Browser
         view.getUniversalListener().scrollToOldest();
 
         // go to top
-        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
+//        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
     }
 
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/NewerAction.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/NewerAction.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/NewerAction.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/NewerAction.java Fri Aug 20 17:07:19 2010
@@ -71,7 +71,7 @@ public class NewerAction extends Browser
         view.getUniversalListener().scrollToOldest();
 
         // go to top
-        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
+//        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
     }
 
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsView.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsView.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsView.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsView.java Fri Aug 20 17:07:19 2010
@@ -75,7 +75,7 @@ public class SearchLogsView extends View
      */
     public void setFocus()
     {
-        mainWidget.getSourceViewer().getTextWidget().setFocus();
+//        mainWidget.getSourceViewer().getTextWidget().setFocus();
     }
 
 
@@ -112,7 +112,7 @@ public class SearchLogsView extends View
         // create main widget
         mainWidget = new LdifEditorWidget( null, "", false ); //$NON-NLS-1$
         mainWidget.createWidget( composite );
-        mainWidget.getSourceViewer().setEditable( false );
+//        mainWidget.getSourceViewer().setEditable( false );
 
         // create actions and context menu (and register global actions)
         actionGroup = new SearchLogsViewActionGroup( this );
@@ -123,8 +123,8 @@ public class SearchLogsView extends View
         universalListener = new SearchLogsViewUniversalListener( this );
 
         // set help context
-        PlatformUI.getWorkbench().getHelpSystem().setHelp( mainWidget.getSourceViewer().getTextWidget(),
-            BrowserUIConstants.PLUGIN_ID + "." + "tools_search_logs_view" ); //$NON-NLS-1$ //$NON-NLS-2$
+//        PlatformUI.getWorkbench().getHelpSystem().setHelp( mainWidget.getSourceViewer().getTextWidget(),
+//            BrowserUIConstants.PLUGIN_ID + "." + "tools_search_logs_view" ); //$NON-NLS-1$ //$NON-NLS-2$
     }
 
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewActionGroup.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewActionGroup.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewActionGroup.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewActionGroup.java Fri Aug 20 17:07:19 2010
@@ -21,7 +21,6 @@
 package org.apache.directory.studio.ldapbrowser.ui.views.searchlogs;
 
 
-import java.util.HashMap;
 import java.util.Map;
 
 import org.apache.directory.studio.connection.core.ConnectionCoreConstants;
@@ -31,7 +30,6 @@ import org.apache.directory.studio.ldapb
 import org.eclipse.jface.action.IMenuListener;
 import org.eclipse.jface.action.IMenuManager;
 import org.eclipse.jface.action.Separator;
-import org.eclipse.jface.text.source.SourceViewer;
 import org.eclipse.ui.IActionBars;
 
 
@@ -82,17 +80,17 @@ public class SearchLogsViewActionGroup i
     public SearchLogsViewActionGroup( SearchLogsView view )
     {
         this.view = view;
-        SourceViewer viewer = this.view.getMainWidget().getSourceViewer();
+//        SourceViewer viewer = this.view.getMainWidget().getSourceViewer();
 
-        searchLogsViewActionMap = new HashMap<String, SearchLogsViewActionProxy>();
-        searchLogsViewActionMap.put( olderAction, new SearchLogsViewActionProxy( viewer, new OlderAction( view ) ) );
-        searchLogsViewActionMap.put( newerAction, new SearchLogsViewActionProxy( viewer, new NewerAction( view ) ) );
-        searchLogsViewActionMap.put( refreshAction, new SearchLogsViewActionProxy( viewer, new RefreshAction( view ) ) );
-        searchLogsViewActionMap.put( clearAction, new SearchLogsViewActionProxy( viewer, new ClearAction( view ) ) );
-        searchLogsViewActionMap.put( exportAction, new SearchLogsViewActionProxy( viewer, new ExportAction() ) );
-        enableSearchRequestLogsAction = new EnableSearchRequestLogsAction();
-        enableSearchResultEntryLogsAction = new EnableSearchResultEntryLogsAction();
-        openSearchLogsPreferencePageAction = new OpenSearchLogsPreferencePageAction();
+//        searchLogsViewActionMap = new HashMap<String, SearchLogsViewActionProxy>();
+//        searchLogsViewActionMap.put( olderAction, new SearchLogsViewActionProxy( viewer, new OlderAction( view ) ) );
+//        searchLogsViewActionMap.put( newerAction, new SearchLogsViewActionProxy( viewer, new NewerAction( view ) ) );
+//        searchLogsViewActionMap.put( refreshAction, new SearchLogsViewActionProxy( viewer, new RefreshAction( view ) ) );
+//        searchLogsViewActionMap.put( clearAction, new SearchLogsViewActionProxy( viewer, new ClearAction( view ) ) );
+//        searchLogsViewActionMap.put( exportAction, new SearchLogsViewActionProxy( viewer, new ExportAction() ) );
+//        enableSearchRequestLogsAction = new EnableSearchRequestLogsAction();
+//        enableSearchResultEntryLogsAction = new EnableSearchResultEntryLogsAction();
+//        openSearchLogsPreferencePageAction = new OpenSearchLogsPreferencePageAction();
     }
 
 
@@ -127,30 +125,30 @@ public class SearchLogsViewActionGroup i
      */
     public void fillActionBars( IActionBars actionBars )
     {
-        // Tool Bar
-        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( clearAction ) );
-        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( refreshAction ) );
-        actionBars.getToolBarManager().add( new Separator() );
-        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( olderAction ) );
-        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( newerAction ) );
-        actionBars.getToolBarManager().add( new Separator() );
-        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( exportAction ) );
-
-        // Menu Bar
-        actionBars.getMenuManager().add( enableSearchRequestLogsAction );
-        actionBars.getMenuManager().add( enableSearchResultEntryLogsAction );
-        actionBars.getMenuManager().add( new Separator() );
-        actionBars.getMenuManager().add( openSearchLogsPreferencePageAction );
-        actionBars.getMenuManager().addMenuListener( new IMenuListener()
-        {
-            public void menuAboutToShow( IMenuManager manager )
-            {
-                enableSearchRequestLogsAction.setChecked( ConnectionCorePlugin.getDefault().getPluginPreferences()
-                    .getBoolean( ConnectionCoreConstants.PREFERENCE_SEARCHREQUESTLOGS_ENABLE ) );
-                enableSearchResultEntryLogsAction.setChecked( ConnectionCorePlugin.getDefault().getPluginPreferences()
-                    .getBoolean( ConnectionCoreConstants.PREFERENCE_SEARCHRESULTENTRYLOGS_ENABLE ) );
-            }
-        } );
+//        // Tool Bar
+//        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( clearAction ) );
+//        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( refreshAction ) );
+//        actionBars.getToolBarManager().add( new Separator() );
+//        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( olderAction ) );
+//        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( newerAction ) );
+//        actionBars.getToolBarManager().add( new Separator() );
+//        actionBars.getToolBarManager().add( searchLogsViewActionMap.get( exportAction ) );
+//
+//        // Menu Bar
+//        actionBars.getMenuManager().add( enableSearchRequestLogsAction );
+//        actionBars.getMenuManager().add( enableSearchResultEntryLogsAction );
+//        actionBars.getMenuManager().add( new Separator() );
+//        actionBars.getMenuManager().add( openSearchLogsPreferencePageAction );
+//        actionBars.getMenuManager().addMenuListener( new IMenuListener()
+//        {
+//            public void menuAboutToShow( IMenuManager manager )
+//            {
+//                enableSearchRequestLogsAction.setChecked( ConnectionCorePlugin.getDefault().getPluginPreferences()
+//                    .getBoolean( ConnectionCoreConstants.PREFERENCE_SEARCHREQUESTLOGS_ENABLE ) );
+//                enableSearchResultEntryLogsAction.setChecked( ConnectionCorePlugin.getDefault().getPluginPreferences()
+//                    .getBoolean( ConnectionCoreConstants.PREFERENCE_SEARCHRESULTENTRYLOGS_ENABLE ) );
+//            }
+//        } );
     }
 
 
@@ -169,10 +167,10 @@ public class SearchLogsViewActionGroup i
      */
     public void setInput( SearchLogsViewInput input )
     {
-        for ( SearchLogsViewActionProxy action : searchLogsViewActionMap.values() )
-        {
-            action.inputChanged( input );
-        }
+//        for ( SearchLogsViewActionProxy action : searchLogsViewActionMap.values() )
+//        {
+//            action.inputChanged( input );
+//        }
     }
 
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewUniversalListener.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewUniversalListener.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewUniversalListener.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/views/searchlogs/SearchLogsViewUniversalListener.java Fri Aug 20 17:07:19 2010
@@ -181,7 +181,7 @@ public class SearchLogsViewUniversalList
                 }
 
                 // change input
-                view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
+//                view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
                 view.getActionGroup().setInput( input );
             }
         }
@@ -249,7 +249,7 @@ public class SearchLogsViewUniversalList
      */
     public void scrollToOldest()
     {
-        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
+//        view.getMainWidget().getSourceViewer().setTopIndex( 0 );
     }
 
 
@@ -258,18 +258,18 @@ public class SearchLogsViewUniversalList
      */
     public void scrollToNewest()
     {
-        try
-        {
-            LdifContainer record = view.getMainWidget().getLdifModel().getLastContainer();
-            int offset = record.getOffset();
-            int line = view.getMainWidget().getSourceViewer().getDocument().getLineOfOffset( offset );
-            if ( line > 3 )
-                line -= 3;
-            view.getMainWidget().getSourceViewer().setTopIndex( line );
-        }
-        catch ( Exception e )
-        {
-        }
+//        try
+//        {
+//            LdifContainer record = view.getMainWidget().getLdifModel().getLastContainer();
+//            int offset = record.getOffset();
+//            int line = view.getMainWidget().getSourceViewer().getDocument().getLineOfOffset( offset );
+//            if ( line > 3 )
+//                line -= 3;
+//            view.getMainWidget().getSourceViewer().setTopIndex( line );
+//        }
+//        catch ( Exception e )
+//        {
+//        }
     }
 
 
@@ -301,8 +301,8 @@ public class SearchLogsViewUniversalList
                     sb.append( e.getMessage() );
                 }
             }
-            view.getMainWidget().getSourceViewer().setTopIndex( 0 );
-            view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
+//            view.getMainWidget().getSourceViewer().setTopIndex( 0 );
+//            view.getMainWidget().getSourceViewer().getDocument().set( sb.toString() );
         }
     }
 

Modified: directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/wizards/BatchOperationLdifWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/wizards/BatchOperationLdifWizardPage.java?rev=987577&r1=987576&r2=987577&view=diff
==============================================================================
--- directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/wizards/BatchOperationLdifWizardPage.java (original)
+++ directory/studio/branches/studio-rap/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/wizards/BatchOperationLdifWizardPage.java Fri Aug 20 17:07:19 2010
@@ -115,16 +115,16 @@ public class BatchOperationLdifWizardPag
         ldifEditorWidget.createWidget( composite );
         ldifEditorWidget.addWidgetModifyListener( this );
 
-        ldifEditorWidget.getSourceViewer().getTextWidget().addVerifyListener( new VerifyListener()
-        {
-            public void verifyText( VerifyEvent e )
-            {
-                if ( e.start < LDIF_DN_PREFIX.length() || e.end < LDIF_DN_PREFIX.length() )
-                {
-                    e.doit = false;
-                }
-            }
-        } );
+//        ldifEditorWidget.getSourceViewer().getTextWidget().addVerifyListener( new VerifyListener()
+//        {
+//            public void verifyText( VerifyEvent e )
+//            {
+//                if ( e.start < LDIF_DN_PREFIX.length() || e.end < LDIF_DN_PREFIX.length() )
+//                {
+//                    e.doit = false;
+//                }
+//            }
+//        } );
 
         validate();
 



Mime
View raw message