Crossfire Server, Trunk
CREPrePostSingleConditionDelegate Class Reference

#include <CREPrePostConditionDelegate.h>

+ Inheritance diagram for CREPrePostSingleConditionDelegate:
+ Collaboration diagram for CREPrePostSingleConditionDelegate:

Public Member Functions

virtual QWidget * createEditor (QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index) const override
 
 CREPrePostSingleConditionDelegate (QObject *parent, PrePostWidget::Mode mode, const MessageManager *manager)
 
virtual void setEditorData (QWidget *editor, const QModelIndex &index) const override
 
virtual void setModelData (QWidget *editor, QAbstractItemModel *model, const QModelIndex &index) const override
 
virtual void updateEditorGeometry (QWidget *editor, const QStyleOptionViewItem &option, const QModelIndex &index) const override
 

Private Attributes

const MessageManagermyMessages
 
PrePostWidget::Mode myMode
 

Detailed Description

Allow edition a single pre- or post condition.

Definition at line 23 of file CREPrePostConditionDelegate.h.

Constructor & Destructor Documentation

◆ CREPrePostSingleConditionDelegate()

CREPrePostSingleConditionDelegate::CREPrePostSingleConditionDelegate ( QObject *  parent,
PrePostWidget::Mode  mode,
const MessageManager manager 
)

Standard constructor.

Parameters
parentparent of this item.
modelist mode to use.
managermessages manager.

Definition at line 18 of file CREPrePostConditionDelegate.cpp.

Member Function Documentation

◆ createEditor()

QWidget * CREPrePostSingleConditionDelegate::createEditor ( QWidget *  parent,
const QStyleOptionViewItem &  option,
const QModelIndex &  index 
) const
overridevirtual

Definition at line 23 of file CREPrePostConditionDelegate.cpp.

References myMessages, myMode, MessageManager::postConditions(), PrePostWidget::PreConditions, and MessageManager::preConditions().

+ Here is the call graph for this function:

◆ setEditorData()

void CREPrePostSingleConditionDelegate::setEditorData ( QWidget *  editor,
const QModelIndex &  index 
) const
overridevirtual

Definition at line 28 of file CREPrePostConditionDelegate.cpp.

References npc_dialog::index, and CREPrePostPanel::setData().

+ Here is the call graph for this function:

◆ setModelData()

void CREPrePostSingleConditionDelegate::setModelData ( QWidget *  editor,
QAbstractItemModel *  model,
const QModelIndex &  index 
) const
overridevirtual

Definition at line 36 of file CREPrePostConditionDelegate.cpp.

References navar-midane_time::data, CREPrePostPanel::getData(), npc_dialog::index, myMode, and PrePostWidget::SetWhen.

+ Here is the call graph for this function:

◆ updateEditorGeometry()

void CREPrePostSingleConditionDelegate::updateEditorGeometry ( QWidget *  editor,
const QStyleOptionViewItem &  option,
const QModelIndex &  index 
) const
overridevirtual

Definition at line 48 of file CREPrePostConditionDelegate.cpp.

References ring_occidental_mages::r.

Field Documentation

◆ myMessages

const MessageManager* CREPrePostSingleConditionDelegate::myMessages
private

Definition at line 41 of file CREPrePostConditionDelegate.h.

Referenced by createEditor().

◆ myMode

PrePostWidget::Mode CREPrePostSingleConditionDelegate::myMode
private

Definition at line 40 of file CREPrePostConditionDelegate.h.

Referenced by createEditor(), and setModelData().


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