From 583c8c525b0691a0cb2a195ced20969b2e0ff57f Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Thu, 15 Oct 2015 14:04:21 +0200 Subject: Remove deprectated classes and methods --- .../nativewindow/awt/AWTGraphicsConfiguration.java | 21 --------------------- .../com/jogamp/nativewindow/awt/AppContextInfo.java | 15 +++++++-------- .../com/jogamp/nativewindow/awt/JAWTWindow.java | 20 -------------------- 3 files changed, 7 insertions(+), 49 deletions(-) (limited to 'src/nativewindow/classes/com') diff --git a/src/nativewindow/classes/com/jogamp/nativewindow/awt/AWTGraphicsConfiguration.java b/src/nativewindow/classes/com/jogamp/nativewindow/awt/AWTGraphicsConfiguration.java index cc70b6b7b..84fce7fc9 100644 --- a/src/nativewindow/classes/com/jogamp/nativewindow/awt/AWTGraphicsConfiguration.java +++ b/src/nativewindow/classes/com/jogamp/nativewindow/awt/AWTGraphicsConfiguration.java @@ -72,27 +72,6 @@ public class AWTGraphicsConfiguration extends DefaultGraphicsConfiguration imple this.encapsulated=null; } - /** - * @deprecated Use {@link #create(GraphicsConfiguration, CapabilitiesImmutable, CapabilitiesImmutable)} - * Method constructs a new {@link AWTGraphicsConfiguration} primarily based - * on the given {@link Component}'s {@link GraphicsConfiguration}. - * @param awtComp the {@link Component}, which {@link GraphicsConfiguration} is used for the resulting {@link AWTGraphicsConfiguration} - * @param capsChosen if null, capsRequested is copied and aligned - * with the graphics {@link Capabilities} of the AWT Component to produce the chosen {@link Capabilities}. - * Otherwise the capsChosen is used. - * @param capsRequested if null, default {@link Capabilities} are used, otherwise the given values. - */ - public static AWTGraphicsConfiguration create(final Component awtComp, final CapabilitiesImmutable capsChosen, final CapabilitiesImmutable capsRequested) { - if(null==awtComp) { - throw new IllegalArgumentException("Null AWT Component"); - } - final GraphicsConfiguration gc = awtComp.getGraphicsConfiguration(); - if( null == gc ) { - throw new NativeWindowException("Null AWT GraphicsConfiguration @ "+awtComp); - } - return create(gc, capsChosen, capsRequested); - } - /** * Method constructs a new {@link AWTGraphicsConfiguration} primarily based * on the given {@link GraphicsConfiguration}. diff --git a/src/nativewindow/classes/com/jogamp/nativewindow/awt/AppContextInfo.java b/src/nativewindow/classes/com/jogamp/nativewindow/awt/AppContextInfo.java index 2026ada0f..e5dcfa1c0 100644 --- a/src/nativewindow/classes/com/jogamp/nativewindow/awt/AppContextInfo.java +++ b/src/nativewindow/classes/com/jogamp/nativewindow/awt/AppContextInfo.java @@ -97,24 +97,23 @@ public class AppContextInfo { * The resulting thread name will have either '-OnAppContextTG' or '-OnSystemTG' appended * @return the {@link Thread} used to invoke the runnable, which may be the current {@link Thread} or a newly created one, see above. */ - public Thread invokeOnAppContextThread(final boolean waitUntilDone, final Runnable runnable, final String threadBaseName) { - final Thread t; + public RunnableTask invokeOnAppContextThread(final boolean waitUntilDone, final Runnable runnable, final String threadBaseName) { + final RunnableTask rt; if( update("invoke") ) { - t = Thread.currentThread(); + rt = RunnableTask.invokeOnCurrentThread(runnable); if( DEBUG ) { - System.err.println("Bug 1004: Invoke.0 on current AppContext thread: "+t+" "+toHexString(t.hashCode())); + System.err.println("Bug 1004: Invoke.0 on current AppContext: "+rt); } - runnable.run(); } else { final ThreadGroup tg = getCachedThreadGroup(); final String tName = threadBaseName + ( null != tg ? "-OnAppContextTG" : "-OnSystemTG" ); - t = RunnableTask.invokeOnNewThread(tg, waitUntilDone, runnable, tName); + rt = RunnableTask.invokeOnNewThread(tg, tName, waitUntilDone, runnable); if( DEBUG ) { final int tgHash = null != tg ? tg.hashCode() : 0; - System.err.println("Bug 1004: Invoke.1 on new AppContext thread: "+t+" "+toHexString(t.hashCode())+", tg "+tg+" "+toHexString(tgHash)); + System.err.println("Bug 1004: Invoke.1 on new AppContext: "+rt+", tg "+tg+" "+toHexString(tgHash)); } } - return t; + return rt; } /** diff --git a/src/nativewindow/classes/com/jogamp/nativewindow/awt/JAWTWindow.java b/src/nativewindow/classes/com/jogamp/nativewindow/awt/JAWTWindow.java index 1dce7428f..71a7602e6 100644 --- a/src/nativewindow/classes/com/jogamp/nativewindow/awt/JAWTWindow.java +++ b/src/nativewindow/classes/com/jogamp/nativewindow/awt/JAWTWindow.java @@ -402,26 +402,6 @@ public abstract class JAWTWindow implements NativeWindow, OffscreenLayerSurface, return hasPixelScaleChanged; } } - /** - * @deprecated Use {@link #updatePixelScale(GraphicsConfiguration, boolean)}. - */ - public final boolean updatePixelScale(final boolean clearFlag) { - return updatePixelScale(awtConfig.getAWTGraphicsConfiguration(), clearFlag); - } - - /** - * @deprecated Use {@link #updateLockedData(JAWT_Rectangle, GraphicsConfiguration)}. - */ - protected final boolean updateLockedData(final JAWT_Rectangle jawtBounds) { - throw new RuntimeException("Invalid API entry"); - } - /** - * @deprecated Use {@link #lockSurfaceImpl(GraphicsConfiguration)} - */ - protected int lockSurfaceImpl() throws NativeWindowException { - throw new RuntimeException("Invalid API entry"); - } - /** * Returns and clears the {@code hasPixelScaleChanged} flag, as set via {@link #lockSurface()}. -- cgit v1.2.3