API Documentation
Loading...
Searching...
No Matches
NDEVRActivationDialog.h
Go to the documentation of this file.
1#pragma once
2#include <NDEVR/String.h>
3#if NDEVR_SECURITY
4#include <QWidget>
5#include <functional>
6namespace Ui
7{
8 class NDEVRActivationDialogUI;
9}
10namespace NDEVR
11{
12 class File;
13 class FileChooserDialog;
14 class NDEVRActivationDialog : public QWidget
15 {
16 Q_OBJECT
17 public:
18 NDEVRActivationDialog(QWidget* parent = nullptr);
19 ~NDEVRActivationDialog();
20 static void PerformActivationCheck();
21 virtual void showEvent(QShowEvent* event) override;
22 virtual void hideEvent(QHideEvent* event) override;
23 void updateInformationUI();
24 void setActivationID(const String& id);
25 void saveOptions();
26 void tryToActivate();
27 void showButtons(bool buttons);
28 void onActivationFileSelected(const File& file);
29 void updateInternetTime();
30 void updateDemoTimes();
31 String activationCode() const;
32 public:
33 static void SetActivationDialogShowing(bool is_showing);
34 static void SetShowActivationOverride(std::function<void()> function);
35 protected:
36 void retranslate();
37 signals:
38 void onActivatedSignal();
39 void onActivationFailedSignal();
40 void onAcceptedSignal();
41 protected:
42 void onIncorrectActivation();
43 void onCorrectActivation();
44 protected:
45 static bool s_is_activation_showing;
46 static bool s_has_shown_activation_dialog;
47 Ui::NDEVRActivationDialogUI* ui;
48 FileChooserDialog* m_selection_dialog = nullptr;
49 bool m_showing_file_browser = false;
50 String m_activation_id;
51 static std::function<void()> s_show_activation_override;
52 };
53}
54#endif
Definition ACIColor.h:37
Definition FontEditor.h:6