Skip to content

Commit 7596426

Browse files
committed
Minor bugfix
1 parent b3b7c68 commit 7596426

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

Orange/canvas/application/canvasmain.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,8 @@ def setup_notifications(self):
390390
settings = config.settings()
391391

392392
# If run for the fifth time, prompt short survey
393-
show_survey = settings["startup/show-survey"] and (settings["startup/launch-count"] >= 5)
393+
show_survey = settings["startup/show-short-survey"] and \
394+
settings["startup/launch-count"] >= 5
394395
if show_survey:
395396
surveyDialogButtons = NotificationWidget.Ok | NotificationWidget.Close
396397
surveyDialog = NotificationWidget(parent=self.scheme_widget,
@@ -404,9 +405,9 @@ def handle_survey_response(button):
404405
if surveyDialog.buttonRole(button) == NotificationWidget.AcceptRole:
405406
success = QDesktopServices.openUrl(
406407
QUrl("https://orange.biolab.si/survey/short.html"))
407-
settings["startup/show-survey"] = not success
408+
settings["startup/show-short-survey"] = not success
408409
elif surveyDialog.buttonRole(button) == NotificationWidget.RejectRole:
409-
settings["startup/show-survey"] = False
410+
settings["startup/show-short-survey"] = False
410411

411412
surveyDialog.clicked.connect(handle_survey_response)
412413

Orange/canvas/config.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,9 @@ def init():
6262
("startup/latest-skipped-version", str, "",
6363
"Latest skipped Orange update"),
6464

65+
("startup/show-short-survey", bool, True,
66+
"Has the user not been asked to take a short survey yet"),
67+
6568
("stylesheet", str, "orange",
6669
"QSS stylesheet to use"),
6770

0 commit comments

Comments
 (0)