All Downloads are FREE. Search and download functionalities are using the official Maven repository.

javajs.swing.JPopupMenu Maven / Gradle / Ivy

There is a newer version: 14.31.10
Show newest version
package javajs.swing;

import javajs.awt.Component;

public class JPopupMenu extends AbstractButton {
  
  // note that in Java Swing JPopupMenu extends 
  // JComponent, but here we extend AbstractButton
  // so that it shares the SwingComponent interface
  
  boolean tainted = true;

  static {
    /**
     * @j2sNative
     * 
     *            SwingController.setDraggable(javajs.swing.JPopupMenu); 
     */
    {
    }
  }
  
  public JPopupMenu(String name) {
    super("mnu");
    this.name = name;
  }

  public void setInvoker(Object applet) {
    this.applet = applet;
    /**
     * @j2sNative
     * 
     * SwingController.setMenu(this);
     * 
     */
    {}
  }
  
  /**
   * @param applet  
   * @param x 
   * @param y 
   */
  public void show(Component applet, int x, int y) {
    /**
     * @j2sNative
     * 
     * if (applet != null)
     *   this.tainted = true;
     * SwingController.showMenu(this, x, y);
     * 
     */
    {}
  }

  public void disposeMenu() {
    /**
     * @j2sNative
     * 
     * SwingController.disposeMenu(this);
     */
    {}
  }
  
  @Override
  public String toHTML() {
    return getMenuHTML();
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy