38 ClassImp(TEveSecondarySelectable);
43 TEveSecondarySelectable::TEveSecondarySelectable() :
44 fAlwaysSecSelect(kFALSE)
51 void TEveSecondarySelectable::ProcessGLSelection(TGLSelectRecord& rec)
53 if (rec.GetHighlight())
54 ProcessGLSelectionInternal(rec, fHighlightedSet);
56 ProcessGLSelectionInternal(rec, fSelectedSet);
62 void TEveSecondarySelectable::ProcessGLSelectionInternal(TGLSelectRecord& rec,
65 Int_t
id = (rec.GetN() > 1) ? (Int_t) rec.GetItem(1) : -1;
72 rec.SetSecSelResult(TGLSelectRecord::kEnteringSelection);
79 if (rec.GetMultiple())
81 if (sset.find(
id) == sset.end())
84 rec.SetSecSelResult(TGLSelectRecord::kModifyingInternalSelection);
90 rec.SetSecSelResult(TGLSelectRecord::kLeavingSelection);
92 rec.SetSecSelResult(TGLSelectRecord::kModifyingInternalSelection);
97 if (sset.size() != 1 || sset.find(
id) == sset.end())
101 rec.SetSecSelResult(TGLSelectRecord::kModifyingInternalSelection);
107 if (!rec.GetMultiple())
110 rec.SetSecSelResult(TGLSelectRecord::kLeavingSelection);
115 if (rec.GetSecSelResult() != TGLSelectRecord::kNone)
117 dynamic_cast<TEveElement*
>(
this)->StampColorSelection();