FileDocCategorySizeDatePackage
DrawingSurfaceJAWT.javaAPI DocJMF 2.1.1e2114Mon May 12 12:20:50 BST 2003com.sun.media

DrawingSurfaceJAWT

public class DrawingSurfaceJAWT extends Object

Fields Summary
public static final int
valid
public static final int
pawt
public static final int
pds
public static final int
pwinid
public static final int
pdisp
private static boolean
avail
int[]
winfo
Constructors Summary
public DrawingSurfaceJAWT()


      
	if ( !avail ) {
	    throw new RuntimeException("can't load jmfjawt native module");
	}

	// System.out.println("in DrawingSurfaceJAWT constructor");
	winfo = new int[5];
	for ( int i = 0; i < 5; i++)
	    winfo[i] = 0;

    
Methods Summary
public static native voidfreeResource(int awtObj, int dsObj)

public native intgetAWT()

public native intgetDrawingSurface(java.awt.Component c, int awtObj)

public native intgetDrawingSurfaceDisplay(int dsObj)

public native intgetDrawingSurfaceWinID(int dsObj)

public static native intgetWindowHandle(java.awt.Component c)

public int[]getWindowInfo(java.awt.Component cc)

	int value = 0;
	value  = getAWT();
	if ( value == 0 ) {
	    winfo[valid] = 0;
	    return winfo;
	}
	winfo[pawt] = value;
	
	value = getDrawingSurface(cc, winfo[pawt]);
	if ( value == 0 ) {
	    winfo[valid] = 0;
	    return winfo;
	}

	winfo[pds] = value;
	
	value = getDrawingSurfaceWinID(winfo[pds]);
	if ( value == 0 ) {
	    winfo[valid] = 0;
	    return winfo;
	}
	    
	winfo[pwinid] = value;

	value = getDrawingSurfaceDisplay(winfo[pds]);
	if ( value == 0 ) {
	    winfo[valid] = 0;
	    return winfo;
	}

	winfo[pdisp] = value;
	winfo[valid] = 1;
	
	return winfo;
    
public static native booleanlockAWT(int dsObj)

public static native voidunlockAWT(int dsObj)