Path: add cursor waiting decorator to long running functions.

Remove obsolete ToolDescription code from label change.
This commit is contained in:
sliptonic
2017-05-11 09:47:33 -05:00
committed by wmayer
parent 38aeb8f8de
commit 6bd6cc0526
3 changed files with 5 additions and 11 deletions

View File

@@ -25,14 +25,11 @@
from __future__ import print_function
import sys
import FreeCAD
# from FreeCAD import Vector
import Path
import PathScripts.PathLog as PathLog
# import Part
from PySide import QtCore, QtGui
from PathScripts import PathUtils
from PathScripts.PathUtils import fmt
# from math import pi
from PathScripts.PathUtils import fmt, waiting_effects
import ArchPanel
@@ -105,9 +102,8 @@ class ObjectDrilling:
def onChanged(self, obj, prop):
pass
# if prop == "UserLabel":
# obj.Label = obj.UserLabel + " :" + obj.ToolDescription
@waiting_effects
def execute(self, obj):
PathLog.track()
output = ""

View File

@@ -109,9 +109,6 @@ class ObjectPocket:
obj.setEditorMode('RampAngle', 2) # make this hidden
obj.setEditorMode('RampSize', 2) # make this hidden
if prop == "UserLabel":
obj.Label = obj.UserLabel + " :" + obj.ToolDescription
def __getstate__(self):
return None

View File

@@ -27,6 +27,7 @@ import FreeCAD
import Path
from PathScripts import PathUtils
import PathScripts.PathLog as PathLog
from PathScripts.PathUtils import waiting_effects
import sys
# xrange is not available in python3
@@ -129,8 +130,7 @@ class ObjectSurface:
return None
def onChanged(self, obj, prop):
if prop == "UserLabel":
obj.Label = obj.UserLabel + " :" + obj.ToolDescription
pass
def _waterline(self, obj, s, bb):
import ocl
@@ -262,6 +262,7 @@ class ObjectSurface:
return output
@waiting_effects
def execute(self, obj):
import MeshPart
FreeCAD.Console.PrintWarning(