Added layer view options

This commit is contained in:
Jack Ha 2016-12-30 14:31:53 +01:00
parent 1217281727
commit fc4c60b0dc
9 changed files with 143 additions and 90 deletions

View file

@ -50,6 +50,31 @@ class LayerViewProxy(QObject):
if type(active_view) == LayerView.LayerView.LayerView:
active_view.setLayer(layer_num)
@pyqtSlot(int)
def setLayerViewType(self, layer_view_type):
active_view = self._controller.getActiveView()
if type(active_view) == LayerView.LayerView.LayerView:
active_view.setLayerViewType(layer_view_type)
@pyqtSlot(bool)
def setOnlyColorActiveExtruder(self, only_color_active_extruder):
active_view = self._controller.getActiveView()
if type(active_view) == LayerView.LayerView.LayerView:
active_view.setOnlyColorActiveExtruder(only_color_active_extruder)
# Opacity 0..1
@pyqtSlot(int, float)
def setExtruderOpacity(self, extruder_nr, opacity):
active_view = self._controller.getActiveView()
if type(active_view) == LayerView.LayerView.LayerView:
active_view.setExtruderOpacity(extruder_nr, opacity)
@pyqtSlot(bool)
def setShowTravelMoves(self, show):
active_view = self._controller.getActiveView()
if type(active_view) == LayerView.LayerView.LayerView:
active_view.setShowTravelMoves(show)
def _layerActivityChanged(self):
self.activityChanged.emit()