summaryrefslogtreecommitdiffstats
path: root/src/qtpass.h
diff options
context:
space:
mode:
authorMaciej S. Szmigiero <mail@maciej.szmigiero.name>2019-10-02 22:45:53 +0200
committerMaciej S. Szmigiero <mail@maciej.szmigiero.name>2019-10-02 22:52:04 +0200
commit3454fcf68288b9bd67ce624e591a60d5d2758610 (patch)
treedff13d0ce4484da7b0194f057029b063b1efff68 /src/qtpass.h
parentfc2aed35a9eae1ecede54321fd0644f89f9bd3c3 (diff)
Don't call QtPass::setup() from QtPass class constructor
QtPass::setup() cannot be called from this class constructor as it possibly calls back MainWindow::config() method. QtPass constructor is in turn called from the MainWindow one so the MainWindow object might not be fully constructed yet. It looks like this was introduced in commit bc19f9eeb5bbcd. Rename QtPass::setup() to QtPass::init() and call it explicitly at the end of the MainWindow constructor. Should fix https://github.com/IJHack/QtPass/issues/466, but the whole thing really needs a refactoring to establish a clear QtPass -> MainWindow (or MainWindow -> QtPass) relationship and to make sure there aren't any circular dependencies there (and other similar bugs).
Diffstat (limited to 'src/qtpass.h')
-rw-r--r--src/qtpass.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qtpass.h b/src/qtpass.h
index 707ad5d2..064edfce 100644
--- a/src/qtpass.h
+++ b/src/qtpass.h
@@ -14,6 +14,7 @@ public:
QtPass(MainWindow *mainWindow);
~QtPass();
+ bool init();
void setClippedText(const QString &, const QString &p_output = QString());
void clearClippedText();
void setClipboardTimer();
@@ -30,7 +31,6 @@ private:
bool freshStart;
void setMainWindow();
- bool setup();
void connectPassSignalHandlers(Pass *pass);
void mountWebDav();