From 83bc42d22a4d628d298e8902b6a76d932065acf6 Mon Sep 17 00:00:00 2001
From: Andrey Loskutov
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleAttributeListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleAttributeListener.java
index d3a7899c102..936f0223a13 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleAttributeListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleAttributeListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.SWTEventListener;
/**
* Classes which implement this interface provide methods
@@ -31,7 +31,7 @@
*
* @since 3.6
*/
-public interface AccessibleAttributeListener extends EventListener {
+public interface AccessibleAttributeListener extends SWTEventListener {
/**
* Returns attributes specific to this Accessible object.
*
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleControlListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleControlListener.java
index 79f69fb321d..e938a35adcb 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleControlListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleControlListener.java
@@ -14,7 +14,7 @@
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes that implement this interface provide methods
@@ -43,7 +43,7 @@
*
* @since 2.0
*/
-public interface AccessibleControlListener extends EventListener {
+public interface AccessibleControlListener extends SWTEventListener {
/**
* Sent when an accessibility client requests the identifier
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleEditableTextListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleEditableTextListener.java
index 723cee24292..c7a930bc063 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleEditableTextListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleEditableTextListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.SWTEventListener;
/**
* Classes which implement this interface provide methods
@@ -31,7 +31,7 @@
*
* @since 3.7
*/
-public interface AccessibleEditableTextListener extends EventListener {
+public interface AccessibleEditableTextListener extends SWTEventListener {
/**
* Copies the substring beginning at the specified
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableListener.java
index bb5c96bc9b4..ec901d305a2 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide methods
@@ -35,7 +35,7 @@
*
* @since 3.6
*/
-public interface AccessibleTableListener extends EventListener {
+public interface AccessibleTableListener extends SWTEventListener {
/**
* Deselects one column, leaving other selected columns selected (if any).
*
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTextListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTextListener.java
index 3eef243cb4c..e0291256a7e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTextListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTextListener.java
@@ -14,7 +14,7 @@
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes that implement this interface provide methods
@@ -43,7 +43,7 @@
*
* @since 3.0
*/
-public interface AccessibleTextListener extends EventListener {
+public interface AccessibleTextListener extends SWTEventListener {
/**
* Sent when an accessibility client requests the current character offset
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleValueListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleValueListener.java
index 95943fc6557..e012164c34c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleValueListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleValueListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.SWTEventListener;
/**
* Classes which implement this interface provide methods
@@ -30,7 +30,7 @@
*
* @since 3.6
*/
-public interface AccessibleValueListener extends EventListener {
+public interface AccessibleValueListener extends SWTEventListener {
/**
* Returns the value of this object as a number.
*
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/AuthenticationListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/AuthenticationListener.java
index 8d62e4e24d2..1e855def681 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/AuthenticationListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/AuthenticationListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -26,7 +26,7 @@
* @since 3.5
*/
@FunctionalInterface
-public interface AuthenticationListener extends EventListener {
+public interface AuthenticationListener extends SWTEventListener {
/**
* This method is called when a page is navigated to that requires
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/CloseWindowListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/CloseWindowListener.java
index 9ce52d6456a..a35b08c0c4e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/CloseWindowListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/CloseWindowListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -29,7 +29,7 @@
* @since 3.0
*/
@FunctionalInterface
-public interface CloseWindowListener extends EventListener {
+public interface CloseWindowListener extends SWTEventListener {
/**
* This method is called when the window hosting a {@link Browser} should be closed.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/LocationListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/LocationListener.java
index 33d5aaee3bf..5a37109e0b9 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/LocationListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/LocationListener.java
@@ -13,9 +13,10 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* This listener interface may be implemented in order to receive
* a {@link LocationEvent} notification when a {@link Browser}
@@ -27,7 +28,7 @@
*
* @since 3.0
*/
-public interface LocationListener extends EventListener {
+public interface LocationListener extends SWTEventListener {
/**
* This method is called when the current location is about to be changed.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/OpenWindowListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/OpenWindowListener.java
index 7431911d762..8dc165fa0ac 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/OpenWindowListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/OpenWindowListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -28,7 +28,7 @@
* @since 3.0
*/
@FunctionalInterface
-public interface OpenWindowListener extends EventListener {
+public interface OpenWindowListener extends SWTEventListener {
/**
* This method is called when a new window needs to be created.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/ProgressListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/ProgressListener.java
index 9dc9f9ac3c6..c24333f051f 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/ProgressListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/ProgressListener.java
@@ -13,9 +13,10 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* This listener interface may be implemented in order to receive
* a {@link ProgressEvent} notification when a {@link Browser}
@@ -28,7 +29,7 @@
*
* @since 3.0
*/
-public interface ProgressListener extends EventListener {
+public interface ProgressListener extends SWTEventListener {
/**
* This method is called when a progress is made during the loading of the
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/StatusTextListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/StatusTextListener.java
index a05bb0b8c73..93786c48ac6 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/StatusTextListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/StatusTextListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -26,7 +26,7 @@
* @since 3.0
*/
@FunctionalInterface
-public interface StatusTextListener extends EventListener {
+public interface StatusTextListener extends SWTEventListener {
/**
* This method is called when the status text is changed. The
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/TitleListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/TitleListener.java
index 72e5b92ffda..3fa84cf2b1b 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/TitleListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/TitleListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -26,7 +26,7 @@
* @since 3.0
*/
@FunctionalInterface
-public interface TitleListener extends EventListener {
+public interface TitleListener extends SWTEventListener {
/**
* This method is called when the title of the current document
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/VisibilityWindowListener.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/VisibilityWindowListener.java
index 3d61aa763ef..cbb88c78b33 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/VisibilityWindowListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/VisibilityWindowListener.java
@@ -13,9 +13,10 @@
*******************************************************************************/
package org.eclipse.swt.browser;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* This listener interface may be implemented in order to receive
* a {@link WindowEvent} notification when a window hosting a
@@ -28,7 +29,7 @@
*
* @since 3.0
*/
-public interface VisibilityWindowListener extends EventListener {
+public interface VisibilityWindowListener extends SWTEventListener {
/**
* This method is called when the window hosting a start
offset
* and extending to the character at offset end - 1
to the clipboard.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleHyperlinkListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleHyperlinkListener.java
index bb17eb1493b..de02c6b497b 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleHyperlinkListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleHyperlinkListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.SWTEventListener;
/**
* Classes which implement this interface provide methods
@@ -30,7 +30,7 @@
*
* @since 3.6
*/
-public interface AccessibleHyperlinkListener extends EventListener {
+public interface AccessibleHyperlinkListener extends SWTEventListener {
/**
* Returns the anchor for the link at the specified index.
*
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleListener.java
index 0cfca5e4d1f..a18dad8cc2a 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleListener.java
@@ -14,9 +14,10 @@
package org.eclipse.swt.accessibility;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes that implement this interface provide methods
* that deal with the events that are generated when an
@@ -40,7 +41,7 @@
*
* @since 2.0
*/
-public interface AccessibleListener extends EventListener {
+public interface AccessibleListener extends SWTEventListener {
/**
* Sent when an accessibility client requests the name
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableCellListener.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableCellListener.java
index 62042bc1e96..5533da3937f 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableCellListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/common/org/eclipse/swt/accessibility/AccessibleTableCellListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;
-import java.util.*;
+import org.eclipse.swt.internal.SWTEventListener;
/**
* Classes which implement this interface provide methods
@@ -30,7 +30,7 @@
*
* @since 3.6
*/
-public interface AccessibleTableCellListener extends EventListener {
+public interface AccessibleTableCellListener extends SWTEventListener {
/**
* Returns the number of columns occupied by this cell accessible.
* Browser
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/BidiSegmentListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/BidiSegmentListener.java
index 3219f28bff3..ed569214ac9 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/BidiSegmentListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/BidiSegmentListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -21,7 +21,7 @@
* @see BidiSegmentEvent
*/
@FunctionalInterface
-public interface BidiSegmentListener extends EventListener {
+public interface BidiSegmentListener extends SWTEventListener {
/**
* This method is called when a line needs to be reordered for
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolder2Listener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolder2Listener.java
index e71f88fdadb..25e00abeec3 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolder2Listener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolder2Listener.java
@@ -13,9 +13,10 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the events that are generated by the CTabFolder
@@ -34,7 +35,7 @@
*
* @since 3.0
*/
-public interface CTabFolder2Listener extends EventListener {
+public interface CTabFolder2Listener extends SWTEventListener {
/**
* Sent when the user clicks on the close button of an item in the CTabFolder.
@@ -116,7 +117,7 @@ public interface CTabFolder2Listener extends EventListener {
/**
* Sent when the tab items count changes
- *
+ *
* @param event from observed tab folder
* @since 3.124
*/
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderListener.java
index 22a84794bb0..ce2e1a2fd8d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -29,7 +29,7 @@
* @see CTabFolderEvent
*/
@FunctionalInterface
-public interface CTabFolderListener extends EventListener {
+public interface CTabFolderListener extends SWTEventListener {
/**
* Sent when the user clicks on the close button of an item in the CTabFolder. The item being closed is specified
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CaretListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CaretListener.java
index 4633a7dc127..a26605f514d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CaretListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CaretListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -24,7 +24,7 @@
* @since 3.5
*/
@FunctionalInterface
-public interface CaretListener extends EventListener {
+public interface CaretListener extends SWTEventListener {
/**
* This method is called after the caret offset is changed.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/ExtendedModifyListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/ExtendedModifyListener.java
index 995665243b6..3652482bc6d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/ExtendedModifyListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/ExtendedModifyListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -24,7 +24,7 @@
* @see Sample code and further information
*/
@FunctionalInterface
-public interface ExtendedModifyListener extends EventListener {
+public interface ExtendedModifyListener extends SWTEventListener {
/**
* This method is called after a text change occurs.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineBackgroundListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineBackgroundListener.java
index f661636dd3f..41f8bb241b0 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineBackgroundListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineBackgroundListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -24,7 +24,7 @@
* @see Sample code and further information
*/
@FunctionalInterface
-public interface LineBackgroundListener extends EventListener {
+public interface LineBackgroundListener extends SWTEventListener {
/**
* This method is called when a line is about to be drawn in order to get its
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineStyleListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineStyleListener.java
index 9053718a62a..8e2797986ee 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineStyleListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/LineStyleListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -24,7 +24,7 @@
* @see Sample code and further information
*/
@FunctionalInterface
-public interface LineStyleListener extends EventListener {
+public interface LineStyleListener extends SWTEventListener {
/**
* This method is called when a line is about to be drawn in order to get the
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/MovementListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/MovementListener.java
index a4ec7db5003..6fcb0f73cd5 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/MovementListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/MovementListener.java
@@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.SWTEventListener;
/**
* This listener is invoked when a new offset is required based on the current
@@ -27,7 +27,7 @@
*
* @since 3.3
*/
-public interface MovementListener extends EventListener {
+public interface MovementListener extends SWTEventListener {
/**
* This method is called when a new offset is required based on the current
* offset and a movement type.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/PaintObjectListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/PaintObjectListener.java
index 31d82ad6ebd..f4384ad7026 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/PaintObjectListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/PaintObjectListener.java
@@ -14,14 +14,14 @@
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener is invoked when an object needs to be drawn.
*
* @since 3.2
*/
@FunctionalInterface
-public interface PaintObjectListener extends EventListener {
+public interface PaintObjectListener extends SWTEventListener {
/**
* This method is called when an object needs to be drawn.
*
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledTextListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledTextListener.java
index 0ca56132060..293890e0a07 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledTextListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledTextListener.java
@@ -13,13 +13,12 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
-
import org.eclipse.swt.events.*;
+import org.eclipse.swt.internal.*;
import org.eclipse.swt.widgets.*;
class StyledTextListener extends TypedListener {
-StyledTextListener(EventListener listener) {
+StyledTextListener(SWTEventListener listener) {
super(listener);
}
/**
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/TextChangeListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/TextChangeListener.java
index 7352267b424..0585f6ee587 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/TextChangeListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/TextChangeListener.java
@@ -14,7 +14,7 @@
package org.eclipse.swt.custom;
-import java.util.*;
+import org.eclipse.swt.internal.SWTEventListener;
/**
* The StyledText widget implements this listener to receive
@@ -29,7 +29,7 @@
* below. If the entire text is replaced the textSet method
* should be called instead.
*/
-public interface TextChangeListener extends EventListener {
+public interface TextChangeListener extends SWTEventListener {
/**
* This method is called when the content is about to be changed.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/VerifyKeyListener.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/VerifyKeyListener.java
index 87394bc43c5..c2852315a2c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/VerifyKeyListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/VerifyKeyListener.java
@@ -13,9 +13,8 @@
*******************************************************************************/
package org.eclipse.swt.custom;
-import java.util.*;
-
import org.eclipse.swt.events.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -26,7 +25,7 @@
* @see Sample code and further information
*/
@FunctionalInterface
-public interface VerifyKeyListener extends EventListener {
+public interface VerifyKeyListener extends SWTEventListener {
/**
* The following event fields are used:
*
DragSourceListener
class provides event notification to the application for DragSource events.
@@ -26,7 +26,7 @@
* DragSource
is required to take the appropriate cleanup action. In the case of a successful
* move operation, the application must remove the data that was transferred.
DropTargetListener
class provides event notification to the application
@@ -35,7 +35,7 @@
*
* @see DropTargetEvent
*/
-public interface DropTargetListener extends EventListener {
+public interface DropTargetListener extends SWTEventListener {
/**
* The cursor has entered the drop target boundaries.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java
index 0b9e10fd41e..4a034a5dfa8 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java
@@ -13,8 +13,6 @@
*******************************************************************************/
package org.eclipse.swt.widgets;
-import java.util.*;
-
import org.eclipse.swt.*;
import org.eclipse.swt.events.*;
import org.eclipse.swt.internal.*;
@@ -1465,7 +1463,7 @@ public void removeListener (int eventType, Listener listener) {
* @noreference This method is not intended to be referenced by clients.
* @nooverride This method is not intended to be re-implemented or extended by clients.
*/
-protected void removeListener (int eventType, EventListener handler) {
+protected void removeListener (int eventType, SWTEventListener handler) {
checkWidget();
if (handler == null) error (SWT.ERROR_NULL_ARGUMENT);
if (eventTable == null) return;
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ArmListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ArmListener.java
index 801578a4134..bd4a4d3a42d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ArmListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ArmListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -32,7 +32,7 @@
* @see ArmEvent
*/
@FunctionalInterface
-public interface ArmListener extends EventListener {
+public interface ArmListener extends SWTEventListener {
/**
* Sent when a widget is armed, or 'about to be selected'.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ControlListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ControlListener.java
index 16ebb8c086e..d5fd210ec1c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ControlListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ControlListener.java
@@ -14,9 +14,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the events that are generated by moving
@@ -33,7 +34,7 @@
* @see ControlAdapter
* @see ControlEvent
*/
-public interface ControlListener extends EventListener {
+public interface ControlListener extends SWTEventListener {
/**
* Sent when the location (x, y) of a control changes relative
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DisposeListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DisposeListener.java
index a7b8f76e37d..8cb02a8957a 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DisposeListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DisposeListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -33,7 +33,7 @@
* @see DisposeEvent
*/
@FunctionalInterface
-public interface DisposeListener extends EventListener {
+public interface DisposeListener extends SWTEventListener {
/**
* Sent when the widget is disposed.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DragDetectListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DragDetectListener.java
index 5c712f8ed3d..1f5f54b4b67 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DragDetectListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/DragDetectListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide methods that deal with the
@@ -33,7 +33,7 @@
* @since 3.3
*/
@FunctionalInterface
-public interface DragDetectListener extends EventListener {
+public interface DragDetectListener extends SWTEventListener {
/**
* Sent when a drag gesture is detected.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ExpandListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ExpandListener.java
index 7be2afd2cb6..3829a9f64ac 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ExpandListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ExpandListener.java
@@ -14,9 +14,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the expanding and collapsing of ExpandItem
s.
@@ -35,7 +36,7 @@
*
* @since 3.2
*/
-public interface ExpandListener extends EventListener {
+public interface ExpandListener extends SWTEventListener {
/**
* Sent when an item is collapsed.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/FocusListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/FocusListener.java
index c7a47490ab2..85802482bf1 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/FocusListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/FocusListener.java
@@ -15,9 +15,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the events that are generated as controls
@@ -34,7 +35,7 @@
* @see FocusAdapter
* @see FocusEvent
*/
-public interface FocusListener extends EventListener {
+public interface FocusListener extends SWTEventListener {
/**
* Sent when a control gets focus.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/GestureListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/GestureListener.java
index d9d338f457c..7193e78ef44 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/GestureListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/GestureListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide methods
@@ -39,7 +39,7 @@
* @since 3.7
*/
@FunctionalInterface
-public interface GestureListener extends EventListener {
+public interface GestureListener extends SWTEventListener {
/**
* Sent when a recognized gesture has occurred.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/HelpListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/HelpListener.java
index bc8bf99b1e5..74eb24a1361 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/HelpListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/HelpListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -33,7 +33,7 @@
* @see HelpEvent
*/
@FunctionalInterface
-public interface HelpListener extends EventListener {
+public interface HelpListener extends SWTEventListener {
/**
* Sent when help is requested for a control, typically
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/KeyListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/KeyListener.java
index 4622df90998..8d55ef2809a 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/KeyListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/KeyListener.java
@@ -15,9 +15,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the events that are generated as keys
@@ -34,7 +35,7 @@
* @see KeyAdapter
* @see KeyEvent
*/
-public interface KeyListener extends EventListener {
+public interface KeyListener extends SWTEventListener {
/**
* Sent when a key is pressed on the system keyboard.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuDetectListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuDetectListener.java
index 8818e370e0b..41d0f3f74e1 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuDetectListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuDetectListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide methods
@@ -36,7 +36,7 @@
* @since 3.3
*/
@FunctionalInterface
-public interface MenuDetectListener extends EventListener {
+public interface MenuDetectListener extends SWTEventListener {
/**
* Sent when the platform-dependent trigger for showing a menu item is detected.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuListener.java
index d2297b8b744..a16bdc73130 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MenuListener.java
@@ -14,9 +14,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the hiding and showing of menus.
@@ -32,7 +33,7 @@
* @see MenuAdapter
* @see MenuEvent
*/
-public interface MenuListener extends EventListener {
+public interface MenuListener extends SWTEventListener {
/**
* Sent when a menu is hidden.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ModifyListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ModifyListener.java
index b2339912a6f..108e3501a19 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ModifyListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ModifyListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -32,7 +32,7 @@
* @see ModifyEvent
*/
@FunctionalInterface
-public interface ModifyListener extends EventListener {
+public interface ModifyListener extends SWTEventListener {
/**
* Sent when the text is modified.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseListener.java
index 1fb488c882b..ec7c13d4534 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseListener.java
@@ -15,9 +15,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the events that are generated as mouse buttons
@@ -34,7 +35,7 @@
* @see MouseAdapter
* @see MouseEvent
*/
-public interface MouseListener extends EventListener {
+public interface MouseListener extends SWTEventListener {
/**
* Sent when a mouse button is pressed twice within the
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseMoveListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseMoveListener.java
index 775ca52e446..5912e65f074 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseMoveListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseMoveListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -32,7 +32,7 @@
* @see MouseEvent
*/
@FunctionalInterface
-public interface MouseMoveListener extends EventListener {
+public interface MouseMoveListener extends SWTEventListener {
/**
* Sent when the mouse moves.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseTrackListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseTrackListener.java
index 60cc0e07a89..135d78be752 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseTrackListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseTrackListener.java
@@ -14,9 +14,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the events that are generated as the mouse
@@ -34,7 +35,7 @@
* @see MouseTrackAdapter
* @see MouseEvent
*/
-public interface MouseTrackListener extends EventListener {
+public interface MouseTrackListener extends SWTEventListener {
/**
* Sent when the mouse pointer passes into the area of
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseWheelListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseWheelListener.java
index 8d0c8f5caf0..8766e14bad1 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseWheelListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/MouseWheelListener.java
@@ -14,7 +14,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -34,7 +34,7 @@
* @since 3.3
*/
@FunctionalInterface
-public interface MouseWheelListener extends EventListener {
+public interface MouseWheelListener extends SWTEventListener {
/**
* Sent when the mouse wheel is scrolled.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/PaintListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/PaintListener.java
index baa0863de37..070c3e919bd 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/PaintListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/PaintListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide methods
@@ -33,7 +33,7 @@
* @see PaintEvent
*/
@FunctionalInterface
-public interface PaintListener extends EventListener {
+public interface PaintListener extends SWTEventListener {
/**
* Sent when a paint event occurs for the control.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SegmentListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SegmentListener.java
index 75d72a06c64..37016ee9455 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SegmentListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SegmentListener.java
@@ -14,7 +14,7 @@
*******************************************************************************/
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* This listener interface may be implemented in order to receive
@@ -24,7 +24,7 @@
* @since 3.8
*/
@FunctionalInterface
-public interface SegmentListener extends EventListener {
+public interface SegmentListener extends SWTEventListener {
/**
* This method is called when text content is being modified.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SelectionListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SelectionListener.java
index 5acd4c66e71..44e0af96323 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SelectionListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/SelectionListener.java
@@ -15,9 +15,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the events that are generated when selection
@@ -34,7 +35,7 @@
* @see SelectionAdapter
* @see SelectionEvent
*/
-public interface SelectionListener extends EventListener {
+public interface SelectionListener extends SWTEventListener {
/**
* Sent when selection occurs in the control.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ShellListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ShellListener.java
index 2cbc57f5a53..fc30f65eeb5 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ShellListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/ShellListener.java
@@ -14,9 +14,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with changes in state of Shell
s.
@@ -32,7 +33,7 @@
* @see ShellAdapter
* @see ShellEvent
*/
-public interface ShellListener extends EventListener {
+public interface ShellListener extends SWTEventListener {
/**
* Sent when a shell becomes the active window.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TouchListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TouchListener.java
index 6fab49d1256..0c9913a2d02 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TouchListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TouchListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide methods
@@ -39,7 +39,7 @@
* @since 3.7
*/
@FunctionalInterface
-public interface TouchListener extends EventListener {
+public interface TouchListener extends SWTEventListener {
/**
* Sent when a touch sequence begins, changes state, or ends.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TraverseListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TraverseListener.java
index fa0923ce38f..14a51d7883c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TraverseListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TraverseListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -33,7 +33,7 @@
* @see TraverseEvent
*/
@FunctionalInterface
-public interface TraverseListener extends EventListener {
+public interface TraverseListener extends SWTEventListener {
/**
* Sent when a traverse event occurs in a control.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TreeListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TreeListener.java
index 6f7930fc561..ceacdfe690e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TreeListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/TreeListener.java
@@ -14,9 +14,10 @@
package org.eclipse.swt.events;
-import java.util.*;
import java.util.function.*;
+import org.eclipse.swt.internal.*;
+
/**
* Classes which implement this interface provide methods
* that deal with the expanding and collapsing of tree
@@ -33,7 +34,7 @@
* @see TreeAdapter
* @see TreeEvent
*/
-public interface TreeListener extends EventListener {
+public interface TreeListener extends SWTEventListener {
/**
* Sent when a tree branch is collapsed.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/VerifyListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/VerifyListener.java
index 17712879023..06360f5af63 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/VerifyListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/events/VerifyListener.java
@@ -15,7 +15,7 @@
package org.eclipse.swt.events;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide a method
@@ -33,7 +33,7 @@
* @see VerifyEvent
*/
@FunctionalInterface
-public interface VerifyListener extends EventListener {
+public interface VerifyListener extends SWTEventListener {
/**
* Sent when the text is about to be modified.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/ImageLoaderListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/ImageLoaderListener.java
index 6a7b5c04661..6a38575d05d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/ImageLoaderListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/ImageLoaderListener.java
@@ -14,7 +14,7 @@
package org.eclipse.swt.graphics;
-import java.util.*;
+import org.eclipse.swt.internal.*;
/**
* Classes which implement this interface provide methods
@@ -32,7 +32,7 @@
* @see ImageLoaderEvent
*/
@FunctionalInterface
-public interface ImageLoaderListener extends EventListener {
+public interface ImageLoaderListener extends SWTEventListener {
/**
* Sent when image data is either partially or completely loaded.
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/internal/SWTEventListener.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/internal/SWTEventListener.java
new file mode 100644
index 00000000000..2622ded4374
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/internal/SWTEventListener.java
@@ -0,0 +1,33 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 2014 IBM Corporation and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.internal;
+
+
+import java.util.EventListener;
+
+/**
+ * This interface is the cross-platform version of the
+ * java.util.EventListener interface.
+ * + * It is part of our effort to provide support for both J2SE + * and J2ME platforms. Under this scheme, classes need to + * implement SWTEventListener instead of java.util.EventListener. + *
+ *+ * Note: java.util.EventListener is not part of CDC and CLDC. + *
+ * @noreference This interface is not intended to be referenced by clients. + */ +public interface SWTEventListener extends EventListener { +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/widgets/EventTable.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/widgets/EventTable.java index d7b68ef505f..47ca537522d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/widgets/EventTable.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/widgets/EventTable.java @@ -14,8 +14,6 @@ package org.eclipse.swt.widgets; -import java.util.*; - import org.eclipse.swt.*; import org.eclipse.swt.internal.*; @@ -147,7 +145,7 @@ public void unhook (int eventType, Listener listener) { } } -public void unhook (int eventType, EventListener listener) { +public void unhook (int eventType, SWTEventListener listener) { if (types == null) return; for (int i=0; i