Skip to content

Commit

Permalink
Stop using SWTEventListener internally and mark it as deprecated
Browse files Browse the repository at this point in the history
forRemoval

As it:
* is internal
* makes api tools fail thanks to it
* serves no purpose since SWT no longer runs on Java ME

Internally SWT is moved to use java.util.EventListener and as it's the
superclass of SWTEventListener makes all the APIs that taken
SWTEventListener to keep working.
  • Loading branch information
akurtakov committed Nov 25, 2024
1 parent 266cc26 commit f428954
Show file tree
Hide file tree
Showing 63 changed files with 239 additions and 146 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;

import org.eclipse.swt.internal.SWTEventListener;
import java.util.*;

/**
* Classes which implement this interface provide methods
Expand All @@ -30,7 +30,7 @@
*
* @since 3.6
*/
public interface AccessibleActionListener extends SWTEventListener {
public interface AccessibleActionListener extends EventListener {
/**
* Returns the number of accessible actions available in this object.
* <p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;

import org.eclipse.swt.internal.SWTEventListener;
import java.util.*;

/**
* Classes which implement this interface provide methods
Expand All @@ -31,7 +31,7 @@
*
* @since 3.6
*/
public interface AccessibleAttributeListener extends SWTEventListener {
public interface AccessibleAttributeListener extends EventListener {
/**
* Returns attributes specific to this Accessible object.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;


import org.eclipse.swt.internal.*;
import java.util.*;

/**
* Classes that implement this interface provide methods
Expand Down Expand Up @@ -43,7 +42,7 @@
*
* @since 2.0
*/
public interface AccessibleControlListener extends SWTEventListener {
public interface AccessibleControlListener extends EventListener {

/**
* Sent when an accessibility client requests the identifier
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;

import org.eclipse.swt.internal.SWTEventListener;
import java.util.*;

/**
* Classes which implement this interface provide methods
Expand All @@ -31,7 +31,7 @@
*
* @since 3.7
*/
public interface AccessibleEditableTextListener extends SWTEventListener {
public interface AccessibleEditableTextListener extends EventListener {
/**
* Copies the substring beginning at the specified <code>start</code> offset
* and extending to the character at offset <code>end - 1</code> to the clipboard.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;

import org.eclipse.swt.internal.SWTEventListener;
import java.util.*;

/**
* Classes which implement this interface provide methods
Expand All @@ -30,7 +30,7 @@
*
* @since 3.6
*/
public interface AccessibleHyperlinkListener extends SWTEventListener {
public interface AccessibleHyperlinkListener extends EventListener {
/**
* Returns the anchor for the link at the specified index.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,9 @@
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
Expand All @@ -41,7 +40,7 @@
*
* @since 2.0
*/
public interface AccessibleListener extends SWTEventListener {
public interface AccessibleListener extends EventListener {

/**
* Sent when an accessibility client requests the name
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;

import org.eclipse.swt.internal.SWTEventListener;
import java.util.*;

/**
* Classes which implement this interface provide methods
Expand All @@ -30,7 +30,7 @@
*
* @since 3.6
*/
public interface AccessibleTableCellListener extends SWTEventListener {
public interface AccessibleTableCellListener extends EventListener {
/**
* Returns the number of columns occupied by this cell accessible.
* <p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;

import org.eclipse.swt.internal.*;
import java.util.*;

/**
* Classes which implement this interface provide methods
Expand All @@ -35,7 +35,7 @@
*
* @since 3.6
*/
public interface AccessibleTableListener extends SWTEventListener {
public interface AccessibleTableListener extends EventListener {
/**
* Deselects one column, leaving other selected columns selected (if any).
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;


import org.eclipse.swt.internal.*;
import java.util.*;

/**
* Classes that implement this interface provide methods
Expand Down Expand Up @@ -43,7 +42,7 @@
*
* @since 3.0
*/
public interface AccessibleTextListener extends SWTEventListener {
public interface AccessibleTextListener extends EventListener {

/**
* Sent when an accessibility client requests the current character offset
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.accessibility;

import org.eclipse.swt.internal.SWTEventListener;
import java.util.*;

/**
* Classes which implement this interface provide methods
Expand All @@ -30,7 +30,7 @@
*
* @since 3.6
*/
public interface AccessibleValueListener extends SWTEventListener {
public interface AccessibleValueListener extends EventListener {
/**
* Returns the value of this object as a number.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.*;
import java.util.*;

/**
* This listener interface may be implemented in order to receive
Expand All @@ -26,7 +26,7 @@
* @since 3.5
*/
@FunctionalInterface
public interface AuthenticationListener extends SWTEventListener {
public interface AuthenticationListener extends EventListener {

/**
* This method is called when a page is navigated to that requires
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.*;
import java.util.*;

/**
* This listener interface may be implemented in order to receive
Expand All @@ -29,7 +29,7 @@
* @since 3.0
*/
@FunctionalInterface
public interface CloseWindowListener extends SWTEventListener {
public interface CloseWindowListener extends EventListener {

/**
* This method is called when the window hosting a {@link Browser} should be closed.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,9 @@
*******************************************************************************/
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}
Expand All @@ -28,7 +27,7 @@
*
* @since 3.0
*/
public interface LocationListener extends SWTEventListener {
public interface LocationListener extends EventListener {

/**
* This method is called when the current location is about to be changed.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.*;
import java.util.*;

/**
* This listener interface may be implemented in order to receive
Expand All @@ -28,7 +28,7 @@
* @since 3.0
*/
@FunctionalInterface
public interface OpenWindowListener extends SWTEventListener {
public interface OpenWindowListener extends EventListener {

/**
* This method is called when a new window needs to be created.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,9 @@
*******************************************************************************/
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}
Expand All @@ -29,7 +28,7 @@
*
* @since 3.0
*/
public interface ProgressListener extends SWTEventListener {
public interface ProgressListener extends EventListener {

/**
* This method is called when a progress is made during the loading of the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.*;
import java.util.*;

/**
* This listener interface may be implemented in order to receive
Expand All @@ -26,7 +26,7 @@
* @since 3.0
*/
@FunctionalInterface
public interface StatusTextListener extends SWTEventListener {
public interface StatusTextListener extends EventListener {

/**
* This method is called when the status text is changed. The
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*******************************************************************************/
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.*;
import java.util.*;

/**
* This listener interface may be implemented in order to receive
Expand All @@ -26,7 +26,7 @@
* @since 3.0
*/
@FunctionalInterface
public interface TitleListener extends SWTEventListener {
public interface TitleListener extends EventListener {

/**
* This method is called when the title of the current document
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,9 @@
*******************************************************************************/
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
Expand All @@ -29,7 +28,7 @@
*
* @since 3.0
*/
public interface VisibilityWindowListener extends SWTEventListener {
public interface VisibilityWindowListener extends EventListener {

/**
* This method is called when the window hosting a <code>Browser</code>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@
*******************************************************************************/
package org.eclipse.swt.custom;

import org.eclipse.swt.internal.*;
import java.util.*;

/**
* This listener interface may be implemented in order to receive
* BidiSegmentEvents.
* @see BidiSegmentEvent
*/
@FunctionalInterface
public interface BidiSegmentListener extends SWTEventListener {
public interface BidiSegmentListener extends EventListener {

/**
* This method is called when a line needs to be reordered for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,9 @@
*******************************************************************************/
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
Expand All @@ -35,7 +34,7 @@
*
* @since 3.0
*/
public interface CTabFolder2Listener extends SWTEventListener {
public interface CTabFolder2Listener extends EventListener {

/**
* Sent when the user clicks on the close button of an item in the CTabFolder.
Expand Down Expand Up @@ -117,7 +116,7 @@ public interface CTabFolder2Listener extends SWTEventListener {

/**
* Sent when the tab items count changes
*
*
* @param event from observed tab folder
* @since 3.124
*/
Expand Down
Loading

0 comments on commit f428954

Please sign in to comment.