Fix Cam and Assembly module

This commit is contained in:
wmayer 2012-04-07 17:00:12 +02:00
parent ef7c1d4b50
commit 4da08fc48d
4 changed files with 14 additions and 7 deletions

View File

@ -2,14 +2,11 @@ SUBDIRS=Resources
lib_LTLIBRARIES=libAssemblyGui.la AssemblyGui.la
BUILT_SOURCES=\
moc_AssemblyView.cpp
#BUILT_SOURCES
libAssemblyGui_la_SOURCES=\
AppAssemblyGuiPy.cpp \
Command.cpp \
AssemblyView.cpp \
AssemblyView.h \
PreCompiled.cpp \
PreCompiled.h \
Workbench.cpp \

View File

@ -88,7 +88,11 @@ SET(Cam_SRCS
add_library(Cam SHARED ${Cam_SRCS})
target_link_libraries(Cam ${Cam_LIBS})
fc_copy_script("Mod/Cam" "Cam" Init.py)
fc_target_copy_resource(Cam
${CMAKE_SOURCE_DIR}/src/Mod/Cam
${CMAKE_BINARY_DIR}/Mod/Cam
Init.py)
if(MSVC)
set_target_properties(Cam PROPERTIES SUFFIX ".pyd")

View File

@ -65,7 +65,11 @@ SET(CamGui_SRCS
add_library(CamGui SHARED ${CamGui_SRCS})
target_link_libraries(CamGui ${CamGui_LIBS})
fc_copy_script("Mod/Cam" "CamGui" InitGui.py)
fc_target_copy_resource(CamGui
${CMAKE_SOURCE_DIR}/src/Mod/Cam
${CMAKE_BINARY_DIR}/Mod/Cam
InitGui.py)
if(MSVC)
set_target_properties(CamGui PROPERTIES SUFFIX ".pyd")

View File

@ -899,7 +899,9 @@ void Cutting::zLevelCallback(void * ud, SoEventCallback * n)
if (!vp || !vp->getTypeId().isDerivedFrom(PartGui::ViewProviderPart::getClassTypeId()))
return;
PartGui::ViewProviderPart* vpp = static_cast<PartGui::ViewProviderPart*>(vp);
TopoDS_Shape sh = vpp->getShape(point);
std::string element = vpp->getElement(point->getDetail());
TopoDS_Shape sh = static_cast<Part::Feature*>(vpp->getObject())->
Shape.getShape().getSubShape(element.c_str());
if (!sh.IsNull())
{
// ok a shape was picked