mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-11-24 03:11:03 -07:00
Merge branch 'ui_rework_4_0' into CURA-5942_printer_selector
This commit is contained in:
commit
a01ff9419d
33 changed files with 1138 additions and 35 deletions
|
|
@ -66,11 +66,19 @@ class GcodeStartEndFormatter(Formatter):
|
|||
return "{" + key + "}"
|
||||
|
||||
key = key_fragments[0]
|
||||
try:
|
||||
return kwargs[str(extruder_nr)][key]
|
||||
except KeyError:
|
||||
|
||||
default_value_str = "{" + key + "}"
|
||||
value = default_value_str
|
||||
# "-1" is global stack, and if the setting value exists in the global stack, use it as the fallback value.
|
||||
if key in kwargs["-1"]:
|
||||
value = kwargs["-1"]
|
||||
if key in kwargs[str(extruder_nr)]:
|
||||
value = kwargs[str(extruder_nr)][key]
|
||||
|
||||
if value == default_value_str:
|
||||
Logger.log("w", "Unable to replace '%s' placeholder in start/end g-code", key)
|
||||
return "{" + key + "}"
|
||||
|
||||
return value
|
||||
|
||||
|
||||
## Job class that builds up the message of scene data to send to CuraEngine.
|
||||
|
|
|
|||
|
|
@ -93,6 +93,11 @@ class FirmwareUpdateCheckerJob(Job):
|
|||
|
||||
current_version = self.getCurrentVersion()
|
||||
|
||||
# This case indicates that was an error checking the version.
|
||||
# It happens for instance when not connected to internet.
|
||||
if current_version == self.ZERO_VERSION:
|
||||
return
|
||||
|
||||
# If it is the first time the version is checked, the checked_version is ""
|
||||
setting_key_str = getSettingsKeyForMachine(machine_id)
|
||||
checked_version = Version(Application.getInstance().getPreferences().getValue(setting_key_str))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue