icon for inactive
This commit is contained in:
@@ -265,12 +265,12 @@ class ObjectOp(object):
|
||||
def onChanged(self, obj, prop):
|
||||
'''onChanged(obj, prop) ... base implementation of the FC notification framework.
|
||||
Do not overwrite, overwrite opOnChanged() instead.'''
|
||||
|
||||
if not 'Restore' in obj.State and prop in ['Base', 'StartDepth', 'FinalDepth']:
|
||||
self.updateDepths(obj, True)
|
||||
|
||||
self.opOnChanged(obj, prop)
|
||||
|
||||
|
||||
def applyExpression(self, obj, prop, expr):
|
||||
'''applyExpression(obj, prop, expr) ... set expression expr on obj.prop if expr is set'''
|
||||
if expr:
|
||||
@@ -436,13 +436,15 @@ class ObjectOp(object):
|
||||
'''
|
||||
PathLog.track()
|
||||
|
||||
if obj.ViewObject:
|
||||
obj.ViewObject.Visibility = obj.Active
|
||||
|
||||
if not obj.Active:
|
||||
path = Path.Path("(inactive operation)")
|
||||
obj.Path = path
|
||||
if obj.ViewObject:
|
||||
obj.ViewObject.Visibility = False
|
||||
return
|
||||
|
||||
|
||||
if not self._setBaseAndStock(obj):
|
||||
return
|
||||
|
||||
|
||||
@@ -145,7 +145,12 @@ class ViewProvider(object):
|
||||
|
||||
def getIcon(self):
|
||||
'''getIcon() ... the icon used in the object tree'''
|
||||
return self.OpIcon
|
||||
if self.Object.Active:
|
||||
return self.OpIcon
|
||||
else:
|
||||
return ":/icons/Path-OpActive.svg"
|
||||
|
||||
#return self.OpIcon
|
||||
|
||||
def getTaskPanelOpPage(self, obj):
|
||||
'''getTaskPanelOpPage(obj) ... use the stored information to instantiate the receiver op's page controller.'''
|
||||
|
||||
Reference in New Issue
Block a user