directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pamarce...@apache.org
Subject svn commit: r515529 - /directory/ldapstudio/trunk/ldapstudio-schemas-plugin/src/main/java/org/apache/directory/ldapstudio/schemas/controller/SchemasViewController.java
Date Wed, 07 Mar 2007 10:52:03 GMT
Author: pamarcelot
Date: Wed Mar  7 02:52:02 2007
New Revision: 515529

URL: http://svn.apache.org/viewvc?view=rev&rev=515529
Log:
Fixed a bug that caused the report of an exception in the .log file ("Detected recursive attempt
for SchemasView to create itself...").
Code Cleaning.

Modified:
    directory/ldapstudio/trunk/ldapstudio-schemas-plugin/src/main/java/org/apache/directory/ldapstudio/schemas/controller/SchemasViewController.java

Modified: directory/ldapstudio/trunk/ldapstudio-schemas-plugin/src/main/java/org/apache/directory/ldapstudio/schemas/controller/SchemasViewController.java
URL: http://svn.apache.org/viewvc/directory/ldapstudio/trunk/ldapstudio-schemas-plugin/src/main/java/org/apache/directory/ldapstudio/schemas/controller/SchemasViewController.java?view=diff&rev=515529&r1=515528&r2=515529
==============================================================================
--- directory/ldapstudio/trunk/ldapstudio-schemas-plugin/src/main/java/org/apache/directory/ldapstudio/schemas/controller/SchemasViewController.java
(original)
+++ directory/ldapstudio/trunk/ldapstudio-schemas-plugin/src/main/java/org/apache/directory/ldapstudio/schemas/controller/SchemasViewController.java
Wed Mar  7 02:52:02 2007
@@ -71,8 +71,8 @@
 import org.eclipse.jface.viewers.TreeViewer;
 import org.eclipse.swt.dnd.DND;
 import org.eclipse.swt.dnd.DropTarget;
+import org.eclipse.swt.dnd.DropTargetAdapter;
 import org.eclipse.swt.dnd.DropTargetEvent;
-import org.eclipse.swt.dnd.DropTargetListener;
 import org.eclipse.swt.dnd.FileTransfer;
 import org.eclipse.swt.dnd.Transfer;
 import org.eclipse.ui.IEditorInput;
@@ -219,7 +219,6 @@
 
         contextMenu = new MenuManager( "" ); //$NON-NLS-1$
         contextMenu.setRemoveAllWhenShown( true );
-
         contextMenu.addMenuListener( new IMenuListener()
         {
             /**
@@ -301,7 +300,7 @@
         Transfer[] types = new Transfer[]
             { FileTransfer.getInstance() };
         target.setTransfer( types );
-        target.addDropListener( new DropTargetListener()
+        target.addDropListener( new DropTargetAdapter()
         {
             /**
              * {@inheritDoc}
@@ -332,38 +331,6 @@
             /**
              * {@inheritDoc}
              */
-            public void dragOver( DropTargetEvent event )
-            {
-            }
-
-
-            /**
-             * {@inheritDoc}
-             */
-            public void dragOperationChanged( DropTargetEvent event )
-            {
-            }
-
-
-            /**
-             * {@inheritDoc}
-             */
-            public void dragLeave( DropTargetEvent event )
-            {
-            }
-
-
-            /**
-             * {@inheritDoc}
-             */
-            public void dropAccept( DropTargetEvent event )
-            {
-            }
-
-
-            /**
-             * {@inheritDoc}
-             */
             public void drop( DropTargetEvent event )
             {
                 if ( fileTransfer.isSupportedType( event.currentDataType ) )
@@ -384,7 +351,6 @@
                 }
             }
         } );
-
     }
 
 
@@ -402,8 +368,6 @@
             {
                 IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
 
-                SchemasView view = ( SchemasView ) PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage()
-                    .findView( SchemasView.ID );
                 TreeViewer viewer = view.getViewer();
 
                 // What we get from the treeViewer is a StructuredSelection
@@ -448,7 +412,6 @@
                 }
             }
         } );
-
     }
 
 
@@ -459,7 +422,7 @@
     private void registerUpdateActions()
     {
         // Handling selection of the Browser View to enable/disable the Actions
-        view.getSite().getPage().addSelectionListener( SchemasView.ID, new ISelectionListener()
+        view.getSite().getPage().addSelectionListener( new ISelectionListener()
         {
             /**
              * {@inheritDoc}



Mime
View raw message