How to get the window handle under the Microsoft JVM?

Davanum Srinivas

import java.awt.*;
import java.awt.peer.*;
import com.ms.awt.peer.*;  

class DrawingCanvas extends java.awt.Canvas
{

  void viewZoomBy(double Factor)
  {
    ....
    ComponentPeer p = this.getPeer();
    if( p != null )
    {
        ComponentPeerX peer1 = (ComponentPeerX)p;
        CompHwnd = peer1.gethwnd();  // Microsoft specific method
    }
    ....
  }
}
0 Comments  (click to add your comment)
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

About | Sitemap | Contact