Only show Welcome-Pages when needed. [CURA-6057]

This commit is contained in:
Remco Burema 2019-03-15 11:30:07 +01:00
parent 0f116fa3f4
commit 4a95564277
2 changed files with 10 additions and 7 deletions

View file

@ -245,8 +245,6 @@ class CuraApplication(QtApplication):
self._update_platform_activity_timer = None
self._need_to_show_user_agreement = True
self._sidebar_custom_menu_items = [] # type: list # Keeps list of custom menu items for the side bar
self._plugins_loaded = False
@ -530,8 +528,6 @@ class CuraApplication(QtApplication):
preferences.addPreference("cura/expanded_brands", "")
preferences.addPreference("cura/expanded_types", "")
self._need_to_show_user_agreement = not preferences.getValue("general/accepted_user_agreement")
for key in [
"dialog_load_path", # dialog_save_path is in LocalFileOutputDevicePlugin
"dialog_profile_path",
@ -553,11 +549,11 @@ class CuraApplication(QtApplication):
@pyqtProperty(bool)
def needToShowUserAgreement(self) -> bool:
return self._need_to_show_user_agreement
return not self.getPreferences().getValue("general/accepted_user_agreement")
@pyqtSlot(bool)
def setNeedToShowUserAgreement(self, set_value = True) -> None:
self._need_to_show_user_agreement = set_value
self.getPreferences().setValue("general/accepted_user_agreement", not set_value)
@pyqtSlot(str, str)
def writeToLog(self, severity: str, message: str) -> None: