Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<?import custommenu.view.ContextMenuPane?>
<AnchorPane xmlns:fx="" fx:controller="custommenu.controller.CustomMenuController">
<VBox fx:id="vbox" onContextMenuRequested="#showMenu"
onMousePressed="#hideMenu" prefHeight="200" prefWidth="200">
<!-- this lets you skip the ContextMenuPane class, but requires all your wiring be done by your controller -->
<!-- scene builder will render this file and simply skip this block -->
<ContextMenu fx:id="menu">
<MenuItem text="add" onAction="#add" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.