Scanframe Modular Application 0.1.0
Loading...
Searching...
No Matches
StoreInspectionDialog.h
Go to the documentation of this file.
1#pragma once
2#include <QAbstractButton>
3#include <QDialog>
4#include <ipj/iface/global.h>
5
6namespace sf
7{
8
9// Forward declaration.
10class TPartInspection;
11
12namespace Ui
13{
14// Forward definition of auto generated class.
15class StoreInspectionDialog;
16}// namespace Ui
17
21class _IPJ_CLASS StoreInspectionDialog final : public QDialog
22{
23 // Macro required for Qt's meta-object system (signals/slots)
24 Q_OBJECT
25
26 public:
41
45 typedef QFlags<EOption> Options;
49 explicit StoreInspectionDialog(QWidget* parent = nullptr);
50
55
60 void setOptions(Options options);
61
66
71 void setPartInspection(const TPartInspection* part_inspection);
72
77
81 int exec() override;
82
83 private:
87 void nameChanged(const QString&);
88
92 bool canClose() const;
93
97 void clicked(QAbstractButton* button);
98
102 Ui::StoreInspectionDialog* ui;
106 Options _options;
110 TPartInspection* _partInspection;
111};
112
113}// namespace sf
Dialog to select a part and project to 'open' or 'save'.
Definition StoreInspectionDialog.h:22
int exec() override
Overridden from base class.
EOption
Options flags for behavior of this dialog.
Definition StoreInspectionDialog.h:31
@ oiSerialSelect
Only select a serial.
Definition StoreInspectionDialog.h:37
@ oiInspectSelect
Only select a specific inspection.
Definition StoreInspectionDialog.h:38
@ oiPartSelect
Only select a part.
Definition StoreInspectionDialog.h:36
@ oiNoPartChange
Part is not allowed to change.
Definition StoreInspectionDialog.h:34
@ oiMustExist
Serial must exist when opening.
Definition StoreInspectionDialog.h:35
@ oiCreate
Special open mode. Source of the part name is taken from the existing projects. The save flag is auto...
Definition StoreInspectionDialog.h:33
@ oiSave
Dialog is for saving.
Definition StoreInspectionDialog.h:32
QFlags< EOption > Options
Options type.
Definition StoreInspectionDialog.h:45
Options options() const
Gets the options set with setOptions and see EOption for the information.
const TPartInspection * getPartInspection() const
Gets the local part project pointer.
void setPartInspection(const TPartInspection *part_inspection)
Assigns the data from the given part project to the local one.
StoreInspectionDialog(QWidget *parent=nullptr)
Default Qt constructor.
void setOptions(Options options)
Sets the options for operation of the dialog and see EOption for the information.
~StoreInspectionDialog() override
Overridden destructor.
Definition PartInspection.h:11
#define _IPJ_CLASS
Definition ipj/iface/global.h:35
Definition ApplicationPropertyPage.h:7
Definition Application.h:10