Project Submission (late)

Dependencies:   mbed

Embed: (wiki syntax)

« Back to documentation index

Menu Class Reference

Menu Class Reference

Menu Class. More...

#include <Menus.h>

Inherited by DefeatMenu, MainMenu, OptionsMenu, StartMenu, and VictoryMenu.

Public Member Functions

 Menu (N5110 *screenPtr)
 Constructor for the Menu base class.
virtual void draw ()
 Virtual draw function, overloaded by Menus to print unique stuff.

Detailed Description

Menu Class.

An abstract class for all Menus's in the program Takes advantage of polymorphism. Draw() function is overriden in every inheriting Menu class. Score is used in the VictoryMenu and DefeatMenu classes.

Due to the similarity of Menu classes and their small size, I did not give them all header and source files.

Instead, classes are defined when they are declared in the same file and Buttons and Menus are grouped

into the same header files based on common functionality.

Version 1.0

Author:
Thomas Caine
Date:
May 2019

Definition at line 58 of file Menus.h.


Constructor & Destructor Documentation

Menu ( N5110 screenPtr )

Constructor for the Menu base class.

Parameters:
lcdpointer - Passed to every menu object (derived classes super this constructor) so they can print to the lcd

Definition at line 68 of file Menus.h.


Member Function Documentation

virtual void draw (  ) [virtual]

Virtual draw function, overloaded by Menus to print unique stuff.

Reimplemented in DefeatMenu, MainMenu, OptionsMenu, StartMenu, and VictoryMenu.

Definition at line 73 of file Menus.h.