Merge branch 'master' of github.com:Ultimaker/Cura

This commit is contained in:
Ghostkeeper 2016-09-20 11:00:57 +02:00
commit 5f023d1efa
No known key found for this signature in database
GPG key ID: 701948C5954A7385
2 changed files with 9 additions and 5 deletions

View file

@ -17,9 +17,10 @@ class SettingInheritanceManager(QObject):
super().__init__(parent)
Application.getInstance().globalContainerStackChanged.connect(self._onGlobalContainerChanged)
self._global_container_stack = None
self._onGlobalContainerChanged()
self._settings_with_inheritance_warning = []
self._active_container_stack = None
self._onGlobalContainerChanged()
cura.Settings.ExtruderManager.getInstance().activeExtruderChanged.connect(self._onActiveExtruderChanged)
self._onActiveExtruderChanged()
@ -58,12 +59,11 @@ class SettingInheritanceManager(QObject):
if new_active_stack != self._active_container_stack:
# Check if changed
self._active_container_stack = new_active_stack
self._update() # Ensure that the settings_with_inheritance_warning list is populated.
self._active_container_stack.propertyChanged.connect(self._onPropertyChanged)
self._update() # Ensure that the settings_with_inheritance_warning list is populated.
def _onPropertyChanged(self, key, property_name):
if property_name == "value" and self._global_container_stack:
definitions = self._global_container_stack.getBottom().findDefinitions(key = key)
if not definitions:
return
@ -149,7 +149,6 @@ class SettingInheritanceManager(QObject):
continue
if has_setting_function:
break # There is a setting function somewhere, stop looking deeper.
return has_setting_function and has_non_function_value
def _update(self):
@ -170,7 +169,12 @@ class SettingInheritanceManager(QObject):
self.settingsWithIntheritanceChanged.emit()
def _onGlobalContainerChanged(self):
if self._global_container_stack:
self._global_container_stack.propertyChanged.disconnect(self._onPropertyChanged)
self._global_container_stack = Application.getInstance().getGlobalContainerStack()
if self._global_container_stack:
self._global_container_stack.propertyChanged.connect(self._onPropertyChanged)
self._onActiveExtruderChanged()
@staticmethod
def createSettingInheritanceManager(engine=None, script_engine=None):

View file

@ -61,7 +61,7 @@ class SliceInfoJob(Job):
# The data is only sent when the user in question gave permission to do so. All data is anonymous and
# no model files are being sent (Just a SHA256 hash of the model).
class SliceInfo(Extension):
info_url = "http://stats.youmagine.com/curastats/slice"
info_url = "https://stats.youmagine.com/curastats/slice"
def __init__(self):
super().__init__()