JDK-8091131 : [Actions] Implement Actions (many toolkits have them, such as Qt)
  • Type: Enhancement
  • Component: javafx
  • Sub-Component: controls
  • Affected Version: 8u5
  • Priority: P4
  • Status: Open
  • Resolution: Unresolved
  • Submitted: 2014-07-15
  • Updated: 2018-09-05
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
tbdUnresolved
Related Reports
Relates :  
Relates :  
Description
As a long time user of the Qt-toolkit I miss something similar to the QAction class (http://qt-project.org/doc/qt-5/qaction.html#details ) in JavaFX.

The class can store a label, an icon and a shortcut and is triggered by user actions when exposed in controls.

In Qt a menu can be built using QActions by just adding the action directly to the menu. The menu shows the icon, the label and the keyboard shortcut.

A toolbar button can also be created using a QAction as its sole constructor argument. It would show just the icon and when triggered an event is emitted in QAction.

This means that a controller can store a set of standard actions and listen to when they are triggered totally ignorant about what type of control sent the event. Many different controls on screen can be linked to the same action (in e.g. menus and toolbars).
Comments
This issue is being somewhat discussed as part of the dialogs Jira issue at RT-12643. Join in there if you have any thoughts on actions.
24-07-2014