added a "Cancel" button to interrupt the server configuration process when it is found that it is busy installing other software

This commit is contained in:
vladimir.kuznetsov 2023-01-02 17:32:27 +03:00
parent 08a8eadb49
commit 6ec090ea0d
17 changed files with 193 additions and 48 deletions

View file

@ -22,6 +22,10 @@ class ServerConfiguringProgressLogic : public PageLogicBase
AUTO_PROPERTY(QString, progressBarText)
AUTO_PROPERTY(bool, labelServerBusyVisible)
AUTO_PROPERTY(QString, labelServerBusyText)
AUTO_PROPERTY(bool, pushButtonCancelVisible)
public:
Q_INVOKABLE void onPushButtonCancelClicked();
private:
struct ProgressFunc {
@ -57,9 +61,13 @@ public:
ErrorCode doInstallAction(const std::function<ErrorCode()> &action,
const PageFunc &page,
const ProgressFunc &progress,
const ButtonFunc &button,
const ButtonFunc &saveButton,
const LabelFunc &waitInfo,
const LabelFunc &serverBusyInfo);
const LabelFunc &serverBusyInfo,
const ButtonFunc &cancelButton);
signals:
void cancelDoInstallAction(const bool cancel);
};
#endif // SERVER_CONFIGURING_PROGRESS_LOGIC_H