Howto:Processing legacy PUI dialogs using Canvas

From FlightGear wiki
Revision as of 19:13, 11 October 2015 by Hooray (talk | contribs) (http://forum.flightgear.org/viewtopic.php?f=71&t=25087&p=260327#p260327)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
This article is a stub. You can help the wiki by expanding it.

Objective

This article is intended to demonstrate how existing PUI dialogs can be easily processed using Nasal/Canvas and turned into Canvas properties.

Approach

We will be registering a custom fgcommand using the addcommand() and patch menubar.xml to change dialog-show fgcommands into canvas-dialog-show for each dialog whose widgets are supported/ported.

For starters, we will focus on simple dialogs, such as exit.xml - however, the framework will be sufficiently generic to also support other widgets/dialogs (as per README.gui).