增加 AbstractFunctionChildrenBox.java 的注释
This commit is contained in:
parent
eb7a599e03
commit
b624d11c7d
@ -6,9 +6,14 @@ import javafx.scene.control.MenuBar;
|
|||||||
import org.jcnc.jnotepad.views.root.bottom.function.FunctionBox;
|
import org.jcnc.jnotepad.views.root.bottom.function.FunctionBox;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 子功能栏抽象类(用于构建一个基本的子功能栏)
|
* 子功能栏抽象类
|
||||||
|
*
|
||||||
|
* <p>
|
||||||
|
* 此抽象类用于构建一个基本的子功能栏,包括功能按钮的初始化和添加到功能栏中。
|
||||||
|
* </p>
|
||||||
*
|
*
|
||||||
* @author gewuyou
|
* @author gewuyou
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
public abstract class AbstractFunctionChildrenBox {
|
public abstract class AbstractFunctionChildrenBox {
|
||||||
protected final FunctionBox functionBox;
|
protected final FunctionBox functionBox;
|
||||||
@ -19,11 +24,17 @@ public abstract class AbstractFunctionChildrenBox {
|
|||||||
|
|
||||||
protected Menu menu = new Menu();
|
protected Menu menu = new Menu();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 构造子功能栏抽象类
|
||||||
|
*/
|
||||||
protected AbstractFunctionChildrenBox() {
|
protected AbstractFunctionChildrenBox() {
|
||||||
functionBox = FunctionBox.getInstance();
|
functionBox = FunctionBox.getInstance();
|
||||||
menuBar = FunctionBox.getMenuBar();
|
menuBar = FunctionBox.getMenuBar();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 初始化子功能栏,包括将功能按钮添加到菜单栏中
|
||||||
|
*/
|
||||||
public void initialize() {
|
public void initialize() {
|
||||||
menu.setGraphic(label);
|
menu.setGraphic(label);
|
||||||
menuBar.getMenus().add(menu);
|
menuBar.getMenus().add(menu);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user