Tome
A generic data editor for games supporting arbitrary input and output formats.
Public Slots | Public Member Functions | Protected Member Functions | List of all members
ListItemWindow Class Reference

Window for editing the value of a single list item. More...

#include <listitemwindow.h>

Inheritance diagram for ListItemWindow:

Public Slots

void accept () Q_DECL_OVERRIDE
 Validates all data and closes this window if successful.
 

Public Member Functions

 ListItemWindow (Tome::FacetsController &facetsController, Tome::ProjectController &projectController, Tome::RecordsController &recordsController, Tome::TypesController &typesController, QWidget *parent=0)
 Constructs a new window for editing the value of a single list item. More...
 
QVariant getValue () const
 Gets the current value of the list item. More...
 
void setValue (const QVariant &value)
 Sets the current value of the list item. More...
 
void setFieldType (const QString &fieldType) const
 Sets the type of the list item. More...
 

Protected Member Functions

virtual void showEvent (QShowEvent *event) Q_DECL_OVERRIDE
 Sets up this window, e.g. by setting the focus on the first widget. More...
 

Detailed Description

Window for editing the value of a single list item.

Constructor & Destructor Documentation

◆ ListItemWindow()

ListItemWindow::ListItemWindow ( Tome::FacetsController facetsController,
Tome::ProjectController projectController,
Tome::RecordsController recordsController,
Tome::TypesController typesController,
QWidget *  parent = 0 
)
explicit

Constructs a new window for editing the value of a single list item.

Parameters
facetsControllerController for validating type facets.
projectControllerController for creating, loading and saving projects.
recordsControllerController for adding, updating and removing records.
typesControllerController for adding, updating and removing custom types.
parentOptional owner widget.

Member Function Documentation

◆ getValue()

QVariant ListItemWindow::getValue ( ) const

Gets the current value of the list item.

Returns
Current value of the list item.

◆ setFieldType()

void ListItemWindow::setFieldType ( const QString &  fieldType) const

Sets the type of the list item.

Parameters
fieldTypeType of the list item.

◆ setValue()

void ListItemWindow::setValue ( const QVariant &  value)

Sets the current value of the list item.

Parameters
valueCurrent value of the list item.

◆ showEvent()

void ListItemWindow::showEvent ( QShowEvent *  event)
protectedvirtual

Sets up this window, e.g. by setting the focus on the first widget.

Parameters
eventEvent for showing this window.

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