FlightGear next
FGNasalMenuBar Class Reference

XML-configured menu bar. More...

#include <FGNasalMenuBar.hxx>

Inherits FGMenuBar.

Classes

class  NasalMenuBarPrivate
 

Public Member Functions

 FGNasalMenuBar ()
 Constructor.
 
virtual ~FGNasalMenuBar ()=default
 
void init () override
 Initialize the menu bar from $FG_ROOT/gui/menubar.xml.
 
void postinit () override
 
void show () override
 Make the menu bar visible.
 
void hide () override
 Make the menu bar invisible.
 
bool isVisible () const override
 Test whether the menu bar is visible.
 
void setHideIfOverlapsWindow (bool hide) override
 Request the menubar to be hidden if its display overlays the main window content.
 
bool getHideIfOverlapsWindow () const override
 
- Public Member Functions inherited from FGMenuBar
 FGMenuBar ()
 
virtual ~FGMenuBar ()
 Destructor.
 

Static Public Member Functions

static void setupGhosts (nasal::Hash &compatModule)
 
- Static Public Member Functions inherited from FGMenuBar
static std::string getLocalizedLabel (SGPropertyNode *node)
 Read a menu label from the menu's property tree.
 

Detailed Description

XML-configured menu bar.

This class creates a menu bar from a tree of XML properties. These properties are not part of the main FlightGear property tree, but are read from a separate file ($FG_ROOT/gui/menubar.xml).

Definition at line 30 of file FGNasalMenuBar.hxx.

Constructor & Destructor Documentation

◆ FGNasalMenuBar()

FGNasalMenuBar::FGNasalMenuBar ( )

Constructor.

Definition at line 326 of file FGNasalMenuBar.cxx.

◆ ~FGNasalMenuBar()

virtual FGNasalMenuBar::~FGNasalMenuBar ( )
virtualdefault

Member Function Documentation

◆ getHideIfOverlapsWindow()

bool FGNasalMenuBar::getHideIfOverlapsWindow ( ) const
overridevirtual

Implements FGMenuBar.

Definition at line 390 of file FGNasalMenuBar.cxx.

◆ hide()

void FGNasalMenuBar::hide ( )
overridevirtual

Make the menu bar invisible.

Implements FGMenuBar.

Definition at line 359 of file FGNasalMenuBar.cxx.

◆ init()

void FGNasalMenuBar::init ( )
overridevirtual

Initialize the menu bar from $FG_ROOT/gui/menubar.xml.

Implements FGMenuBar.

Definition at line 330 of file FGNasalMenuBar.cxx.

◆ isVisible()

bool FGNasalMenuBar::isVisible ( ) const
overridevirtual

Test whether the menu bar is visible.

Implements FGMenuBar.

Definition at line 379 of file FGNasalMenuBar.cxx.

◆ postinit()

void FGNasalMenuBar::postinit ( )
overridevirtual

Reimplemented from FGMenuBar.

Definition at line 336 of file FGNasalMenuBar.cxx.

◆ setHideIfOverlapsWindow()

void FGNasalMenuBar::setHideIfOverlapsWindow ( bool hide)
overridevirtual

Request the menubar to be hidden if its display overlays the main window content.

(Which essentially means the PUI menubar at the moment). This is used to prevent the menubar overlapping the splash-screen during startup.

The state of this flag is independant of the normal menubar visibility, i.e this flag and the normal visibility and AND-ed together inside the code.

Implements FGMenuBar.

Definition at line 384 of file FGNasalMenuBar.cxx.

◆ setupGhosts()

void FGNasalMenuBar::setupGhosts ( nasal::Hash & compatModule)
static

Definition at line 402 of file FGNasalMenuBar.cxx.

◆ show()

void FGNasalMenuBar::show ( )
overridevirtual

Make the menu bar visible.

Implements FGMenuBar.

Definition at line 353 of file FGNasalMenuBar.cxx.


The documentation for this class was generated from the following files: