Open-Typer
Open source typewriting tutor program
Loading...
Searching...
No Matches
AppMenuModel Class Reference

The AppMenuModel class provides a menu model for the application menu bar. More...

#include "framework/ui/menubar/AppMenuModel.h"

Inheritance diagram for AppMenuModel:
Collaboration diagram for AppMenuModel:

Signals

void titleChanged (QString title)
 
void itemsChanged (QList< AppMenuItem * > items)
 

Public Member Functions

 AppMenuModel (QObject *parent=nullptr)
 
QString title (void)
 
void setTitle (QString newTitle)
 
QQmlListProperty< AppMenuItemitems (void)
 
QList< AppMenuItem * > getItems (void)
 
void setItems (QList< AppMenuItem * > newItems)
 
void addItem (AppMenuItem *item)
 
void removeItem (AppMenuItem *item)
 

Properties

QString title
 
QQmlListProperty< AppMenuItemitems
 

Private Attributes

QString m_title
 
QList< AppMenuItem * > m_items
 

Detailed Description

The AppMenuModel class provides a menu model for the application menu bar.

Constructor & Destructor Documentation

◆ AppMenuModel()

AppMenuModel::AppMenuModel ( QObject *  parent = nullptr)
explicit

Constructs AppMenuModel.

Member Function Documentation

◆ addItem()

void AppMenuModel::addItem ( AppMenuItem item)

Adds an item to the menu.

◆ getItems()

QList< AppMenuItem * > AppMenuModel::getItems ( void  )

Returns list of items in the menu.

◆ removeItem()

void AppMenuModel::removeItem ( AppMenuItem item)

Removes an item from the menu.

Property Documentation

◆ items

QQmlListProperty< AppMenuItem > AppMenuModel::items
read

The items in the menu.

◆ title

QString AppMenuModel::title
readwrite

The title of the menu.


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