Dialog for adding a new tool.
More...
#include <addtooldialog.h>
|
void | toolAdded (int app_id, Tool tool) |
| Signals dialog completion in add mode.
|
|
void | toolEdited (int app_id, int tool_id, Tool tool) |
| Signals dialog completion in edit mode.
|
|
|
| AddToolDialog (QWidget *parent=nullptr) |
| Initializes the UI.
|
|
| ~AddToolDialog () |
| Deletes the UI.
|
|
void | setAddMode (int app_id) |
| Initializes the dialog for adding a new tool.
|
|
void | setEditMode (int app_id, int tool_id, Tool tool) |
| Initializes the dialog for editing an existing tool.
|
|
|
void | toolWidgetInputValidityChanged (bool is_valid) |
| Updates the Ok button when the new input is valid.
|
|
void | onButtonBoxAccepted () |
| Closes the dialog and emits a signal for completion.
|
|
|
Ui::AddToolDialog * | ui |
| Contains auto-generated UI elements.
|
|
bool | dialog_completed_ = false |
| Indicates whether the dialog has been completed.
|
|
bool | is_edit_mode_ = false |
| If true: Dialog is used to edit an existing tool. Else: Dialog is used to add a new tool.
|
|
int | app_id_ |
| Id of the app to which the edited tool belongs.
|
|
int | tool_id_ |
| If in edit mode: Id of the edited tool.
|
|
Dialog for adding a new tool.
◆ AddToolDialog()
AddToolDialog::AddToolDialog |
( |
QWidget * | parent = nullptr | ) |
|
|
explicit |
Initializes the UI.
- Parameters
-
parent | Parent for this widget, this is passed to the constructor of QDialog. |
◆ setAddMode()
void AddToolDialog::setAddMode |
( |
int | app_id | ) |
|
Initializes the dialog for adding a new tool.
- Parameters
-
app_id | Id of the app to which the tool is to be added. |
◆ setEditMode()
void AddToolDialog::setEditMode |
( |
int | app_id, |
|
|
int | tool_id, |
|
|
Tool | tool ) |
Initializes the dialog for editing an existing tool.
- Parameters
-
app_id | Id of the app to which the edited tool belongs. |
tool_id | Id of the edited tool. |
tool | The existing tool. |
◆ toolAdded
void AddToolDialog::toolAdded |
( |
int | app_id, |
|
|
Tool | tool ) |
|
signal |
Signals dialog completion in add mode.
- Parameters
-
app_id | Id of the app to which the tool is to be added. |
tool | The new tool. |
◆ toolEdited
void AddToolDialog::toolEdited |
( |
int | app_id, |
|
|
int | tool_id, |
|
|
Tool | tool ) |
|
signal |
Signals dialog completion in edit mode.
- Parameters
-
app_id | Id of the app to which the edited tool belongs. |
tool_id | Id of the edited tool. |
tool | The new tool. |
◆ toolWidgetInputValidityChanged
void AddToolDialog::toolWidgetInputValidityChanged |
( |
bool | is_valid | ) |
|
|
privateslot |
Updates the Ok button when the new input is valid.
- Parameters
-
is_valid | New input validity. |
The documentation for this class was generated from the following files: