use of com.sun.javafx.scene.control.skin.TextAreaSkin in project jabref by JabRef.
the class EditorTextArea method addToContextMenu.
/**
* Adds the given list of menu items to the context menu.
*/
public void addToContextMenu(List<MenuItem> items) {
TextAreaSkin customContextSkin = new TextAreaSkin(this) {
@Override
public void populateContextMenu(ContextMenu contextMenu) {
super.populateContextMenu(contextMenu);
contextMenu.getItems().addAll(0, items);
}
};
setSkin(customContextSkin);
}
Aggregations