Workspace 6.21.5
Classes | Public Member Functions | Protected Types | Protected Slots | Protected Member Functions | Protected Attributes | List of all members
PortReorderDialog Class Referenceabstract

Top-level only abstract tree-based dialog box for reordering operation inputs and outputs. More...

#include <Workspace/Presentation/portreorderdialog.h>

Inheritance diagram for PortReorderDialog:
[legend]

Classes

class  DataState
 Class to carry DataObjects along with whether they were up-to-date. More...
 

Public Member Functions

 PortReorderDialog (int displayWidgetCol, int selectWidgetCol, DataExecution::Workspace &workspace, bool readOnly=false, QWidget *parent=nullptr)
 Creates a dialog box with DisplayWidgets for the values of supplied Updatables.
 
bool isModified ()
 
- Public Member Functions inherited from BasicTextLogger
 BasicTextLogger ()
 
virtual ~BasicTextLogger ()
 
void logLine (const Application::LogManager::MessageCategory &category, const QString &msg) const
 
void logLine (const QString &msg) const
 
void logText (const Application::LogManager::MessageCategory &category, const QString &msg) const
 
void logText (const QString &msg) const
 

Protected Types

typedef QList< DataState * > DataStateList
 

Protected Slots

virtual void okButtonClicked ()=0
 

Protected Member Functions

bool findConnectedDestinations (DataExecution::Output *output, QVariantList &destInputList)
 
void findDObjects (DataExecution::Operation &op, DataStateList &inputDataObjects, DataStateList &outputDataObjects)
 
void findIoBaseProperties (DataExecution::IOBase *ioBase, QStringList &globalNames, QStringList &descriptions, QStringList &names, QStringList &preferredWidgets, QVariantList &dependencySources)
 
void findScalarProperties (DataExecution::IOBase *ioBase, QString &globalName, QString &description, QString &preferredWidget)
 
void findScalarProperties (DataExecution::IOBase *ioBase, QStringList &globalNames, QStringList &descriptions, QStringList &preferredWidgets)
 
void keyPressEvent (QKeyEvent *evt) override
 Stops the dialog box from closing when Enter is pressed **.
 
bool registerItem (QTreeWidgetItem *item, DataExecution::IOBase *ioBase, DisplayWidgetTree::PortType portType, bool readOnly=false)
 
bool removeConnectedDestinations (DataExecution::Output *output)
 
bool removeConnectedSources (DataExecution::InputArray *inputArray)
 
bool restoreConnectedDestinations (DataExecution::Output *output, const QVariantList &destInputList)
 
bool restoreConnectedSources (DataExecution::InputArray *inputArray, const QVariantList &srcOutputList)
 
void restoreDObjects (DataExecution::Operation &op, DataStateList &inputDataObjects, DataStateList &outputDataObjects)
 
void restoreIoBaseProperties (DataExecution::IOBase *ioBase, QStringList &globalNames, QStringList &descriptions, QStringList &names, QStringList &preferredWidgets, const QVariantList &dependencySources)
 
void restoreScalarProperties (DataExecution::IOBase *ioBase, const QString &globalName, const QString &description, const QString &preferredWidget)
 
void restoreScalarProperties (DataExecution::IOBase *ioBase, QStringList &globalNames, QStringList &descriptions, QStringList &preferredWidgets)
 
DataExecution::WorkspacerootWorkspace ()
 

Protected Attributes

DisplayWidgetTree treeWidget_
 
DataExecution::Workspaceworkspace_
 

Detailed Description

Member Typedef Documentation

◆ DataStateList

typedef QList<DataState*> DataStateList
protected

Constructor & Destructor Documentation

◆ PortReorderDialog()

PortReorderDialog ( int  displayWidgetCol,
int  selectWidgetCol,
DataExecution::Workspace workspace,
bool  readOnly = false,
QWidget *  parent = nullptr 
)

You are responsible for populating the tree header and rows. Each row should represent one IOBase item. Create a column for the DisplayWidgets. If you also want to display a QComboBox so that the user can choose from a selection of appropriate DisplayWidgets you should create a column for that too. If you just want to use the Preferred Display Widget for the IOBase, then set the SelectWidgetCol to -1.

Parameters
displayWidgetColindex of the column where you want the display widget
selectWidgetColindex of the column where you want the selection widget (-1 for no selection widget)
workspacewhose ports are to be reordered
readOnlySet this to true if you want all the DisplayWidgets in the tree to be read-only
parentparent widget

**

Member Function Documentation

◆ findConnectedDestinations()

bool findConnectedDestinations ( DataExecution::Output output,
QVariantList &  destInputList 
)
protected

◆ findDObjects()

void findDObjects ( DataExecution::Operation op,
DataStateList inputDataObjects,
DataStateList outputDataObjects 
)
protected

◆ findIoBaseProperties()

void findIoBaseProperties ( DataExecution::IOBase ioBase,
QStringList globalNames,
QStringList descriptions,
QStringList names,
QStringList preferredWidgets,
QVariantList &  dependencySources 
)
protected

Adds properties of an input or output to the property lists

**

◆ findScalarProperties() [1/2]

void findScalarProperties ( DataExecution::IOBase ioBase,
QString &  globalName,
QString &  description,
QString &  preferredWidget 
)
protected

◆ findScalarProperties() [2/2]

void findScalarProperties ( DataExecution::IOBase ioBase,
QStringList globalNames,
QStringList descriptions,
QStringList preferredWidgets 
)
protected

◆ isModified()

bool isModified ( )
inline

◆ keyPressEvent()

void keyPressEvent ( QKeyEvent *  evt)
overrideprotected

◆ okButtonClicked

virtual void okButtonClicked ( )
protectedpure virtualslot

◆ registerItem()

bool registerItem ( QTreeWidgetItem *  item,
DataExecution::IOBase ioBase,
DisplayWidgetTree::PortType  portType,
bool  readOnly = false 
)
protected

◆ removeConnectedDestinations()

bool removeConnectedDestinations ( DataExecution::Output output)
protected

◆ removeConnectedSources()

bool removeConnectedSources ( DataExecution::InputArray inputArray)
protected

◆ restoreConnectedDestinations()

bool restoreConnectedDestinations ( DataExecution::Output output,
const QVariantList &  destInputList 
)
protected

◆ restoreConnectedSources()

bool restoreConnectedSources ( DataExecution::InputArray inputArray,
const QVariantList &  srcOutputList 
)
protected

◆ restoreDObjects()

void restoreDObjects ( DataExecution::Operation op,
DataStateList inputDataObjects,
DataStateList outputDataObjects 
)
protected

◆ restoreIoBaseProperties()

void restoreIoBaseProperties ( DataExecution::IOBase ioBase,
QStringList globalNames,
QStringList descriptions,
QStringList names,
QStringList preferredWidgets,
const QVariantList &  dependencySources 
)
protected

Adds properties of an input or output to the property lists

**

◆ restoreScalarProperties() [1/2]

void restoreScalarProperties ( DataExecution::IOBase ioBase,
const QString &  globalName,
const QString &  description,
const QString &  preferredWidget 
)
protected

◆ restoreScalarProperties() [2/2]

void restoreScalarProperties ( DataExecution::IOBase ioBase,
QStringList globalNames,
QStringList descriptions,
QStringList preferredWidgets 
)
protected

◆ rootWorkspace()

DataExecution::Workspace * rootWorkspace ( )
inlineprotected

Member Data Documentation

◆ treeWidget_

DisplayWidgetTree treeWidget_
protected

◆ workspace_

DataExecution::Workspace& workspace_
protected