From 9c11fdb45ce8d9bc8857be74b7ac553975379cf4 Mon Sep 17 00:00:00 2001 From: Francesco Padovani Date: Sat, 5 Oct 2024 21:45:17 +0200 Subject: [PATCH] fix: open example data from welcome guide, see #564 --- cellacdc/help/welcome.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/cellacdc/help/welcome.py b/cellacdc/help/welcome.py index 2e794e4a..b40ea027 100755 --- a/cellacdc/help/welcome.py +++ b/cellacdc/help/welcome.py @@ -1,5 +1,5 @@ import os, sys -import pathlib +from functools import partial import webbrowser import pandas as pd @@ -888,7 +888,7 @@ def saveSettings(self): def openGUIsingleImage(self): if self.mainWin is not None: self.mainWin.launchGui() - self.mainWin.guiWin.openFile() + self.mainWin.guiWins[-1].openFile() else: self.guiWin = gui.guiWin(self.app) self.guiWin.showAndSetSize() @@ -897,7 +897,10 @@ def openGUIsingleImage(self): def openGUIfolder(self, exp_path): if self.mainWin is not None: self.mainWin.launchGui() - self.mainWin.guiWin.openFolder(exp_path=exp_path) + guiWin = self.mainWin.guiWins[-1] + QTimer.singleShot( + 200, partial(guiWin.openFolder, exp_path=exp_path) + ) else: self.guiWin = gui.guiWin(self.app) self.guiWin.showAndSetSize()