Commit 97b6128d authored by wmayer's avatar wmayer
Browse files

0000911: V0.13- Faces of Solid models cannot be selected when ALT-TAB is used...

0000911: V0.13- Faces of Solid models cannot be selected when ALT-TAB is used to switch between applications
parent 6fe43f96
......@@ -83,6 +83,9 @@ SbBool BlenderNavigationStyle::processSoEvent(const SoEvent * const ev)
// which influence the seek mode itself -- these are handled further
// up the inheritance hierarchy.
if (this->isSeekMode()) { return inherited::processSoEvent(ev); }
// Switch off viewing mode (Bug #0000911)
if (!this->isSeekMode() && this->isViewing())
this->setViewing(false); // by default disable viewing mode to render the scene
const SoType type(ev->getTypeId());
......
......@@ -85,6 +85,7 @@ SbBool CADNavigationStyle::processSoEvent(const SoEvent * const ev)
// up the inheritance hierarchy.
if (this->isSeekMode()) { return inherited::processSoEvent(ev); }
#else
// Switch off viewing mode (Bug #0000911)
if (!this->isSeekMode() && this->isViewing())
this->setViewing(false); // by default disable viewing mode to render the scene
#endif
......
......@@ -83,6 +83,9 @@ SbBool InventorNavigationStyle::processSoEvent(const SoEvent * const ev)
// which influence the seek mode itself -- these are handled further
// up the inheritance hierarchy.
if (this->isSeekMode()) { return inherited::processSoEvent(ev); }
// Switch off viewing mode (Bug #0000911)
if (!this->isSeekMode() && this->isViewing())
this->setViewing(false); // by default disable viewing mode to render the scene
const SoType type(ev->getTypeId());
......
......@@ -105,8 +105,6 @@ SoFCUnifiedSelection::SoFCUnifiedSelection() : viewer(0)
SO_NODE_SET_SF_ENUM_TYPE (highlightMode, HighlightModes);
highlighted = FALSE;
bShift = FALSE;
bCtrl = FALSE;
}
/*!
......@@ -414,22 +412,6 @@ SoFCUnifiedSelection::handleEvent(SoHandleEventAction * action)
}
}
}
// key press events
else if (event->isOfType(SoKeyboardEvent ::getClassTypeId())) {
SoKeyboardEvent * const e = (SoKeyboardEvent *) event;
if (SoKeyboardEvent::isKeyPressEvent(e,SoKeyboardEvent::LEFT_SHIFT) ||
SoKeyboardEvent::isKeyPressEvent(e,SoKeyboardEvent::RIGHT_SHIFT) )
bShift = true;
if (SoKeyboardEvent::isKeyReleaseEvent(e,SoKeyboardEvent::LEFT_SHIFT) ||
SoKeyboardEvent::isKeyReleaseEvent(e,SoKeyboardEvent::RIGHT_SHIFT) )
bShift = false;
if (SoKeyboardEvent::isKeyPressEvent(e,SoKeyboardEvent::LEFT_CONTROL) ||
SoKeyboardEvent::isKeyPressEvent(e,SoKeyboardEvent::RIGHT_CONTROL) )
bCtrl = true;
if (SoKeyboardEvent::isKeyReleaseEvent(e,SoKeyboardEvent::LEFT_CONTROL) ||
SoKeyboardEvent::isKeyReleaseEvent(e,SoKeyboardEvent::RIGHT_CONTROL) )
bCtrl = false;
}
// mouse press events for (de)selection
else if (event->isOfType(SoMouseButtonEvent::getClassTypeId()) &&
selectionMode.getValue() == SoFCUnifiedSelection::ON) {
......@@ -449,7 +431,7 @@ SoFCUnifiedSelection::handleEvent(SoHandleEventAction * action)
std::string documentName = vpd->getObject()->getDocument()->getName();
std::string objectName = vpd->getObject()->getNameInDocument();
std::string subElementName = vpd->getElement(pp ? pp->getDetail() : 0);
if (bCtrl) {
if (event->wasCtrlDown()) {
if (Gui::Selection().isSelected(documentName.c_str()
,objectName.c_str()
,subElementName.c_str())) {
......
......@@ -107,9 +107,6 @@ private:
SbBool highlighted;
SoColorPacker colorpacker;
SbBool bShift;
SbBool bCtrl;
};
/**
......
......@@ -83,6 +83,9 @@ SbBool TouchpadNavigationStyle::processSoEvent(const SoEvent * const ev)
// which influence the seek mode itself -- these are handled further
// up the inheritance hierarchy.
if (this->isSeekMode()) { return inherited::processSoEvent(ev); }
// Switch off viewing mode (Bug #0000911)
if (!this->isSeekMode() && this->isViewing())
this->setViewing(false); // by default disable viewing mode to render the scene
const SoType type(ev->getTypeId());
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment