Added 'design' functionality
This commit is contained in:
@@ -0,0 +1,66 @@
|
||||
/* Author: Maple
|
||||
* Feb. 2 2026
|
||||
* */
|
||||
|
||||
package org.openautonomousconnection.oacswing.component;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.awt.*;
|
||||
|
||||
public class OACMenuItem extends JMenuItem implements OACComponent {
|
||||
public OACMenuItem() {
|
||||
super();
|
||||
}
|
||||
|
||||
public OACMenuItem(Icon icon) {
|
||||
super(icon);
|
||||
}
|
||||
|
||||
public OACMenuItem(String text) {
|
||||
super(text);
|
||||
}
|
||||
|
||||
public OACMenuItem(Action a) {
|
||||
super(a);
|
||||
}
|
||||
|
||||
public OACMenuItem(String text, Icon icon) {
|
||||
super(text, icon);
|
||||
}
|
||||
|
||||
public OACMenuItem(String text, int mnemonic) {
|
||||
super(text, mnemonic);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Component add(Component comp) {
|
||||
this.initOther(comp);
|
||||
return super.add(comp);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Component add(Component comp, int index) {
|
||||
this.initOther(comp);
|
||||
return super.add(comp, index);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void add(@NotNull Component comp, Object constraints) {
|
||||
this.initOther(comp);
|
||||
super.add(comp, constraints);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Component add(String name, Component comp) {
|
||||
this.initOther(comp);
|
||||
return super.add(name, comp);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void add(Component comp, Object constraints, int index) {
|
||||
this.initOther(comp);
|
||||
super.add(comp, constraints, index);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user