ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
AscObjSelectionManager::Imp Class Reference
Collaboration diagram for AscObjSelectionManager::Imp:

Public Member Functions

 Imp (AscObjSelectionManager *tc, SoSeparator *root, IVP13DSystem *sys, TrackSystemController *c)
 
 Imp (const Imp &)=delete
 
Impoperator= (const Imp &)=delete
 
 ~Imp ()
 
AssociatedObjectHandleBaseascObjHandle (const SoPath *)
 
AssociatedObjectHandleBaseascObjHandle (const SoSeparator *)
 
void updateSelectionVisuals ()
 

Static Public Member Functions

static bool shiftIsDown ()
 

Public Attributes

AscObjSelectionManagertheclass
 
SoSeparator * eventRoot
 
IVP13DSystemsystem
 
TrackSystemControllercontroller
 
MODE mode
 
SoCooperativeSelectionsel_assocobjs_click
 
SoCooperativeSelectionsel_assocobjs
 
std::map< SoSeparator *, AssociatedObjectHandleBase * > ascobjs_simpleToHandle
 
std::map< SoSeparator *, AssociatedObjectHandleBase * > ascobjs_detailedToHandle
 
QList< AssociatedObjectHandleBase * > selAscObjHandles
 

Detailed Description

Definition at line 28 of file AscObjSelectionManager.cxx.

Constructor & Destructor Documentation

◆ Imp() [1/2]

AscObjSelectionManager::Imp::Imp ( AscObjSelectionManager tc,
SoSeparator *  root,
IVP13DSystem sys,
TrackSystemController c 
)
inline

Definition at line 30 of file AscObjSelectionManager.cxx.

31  : theclass(tc),
32  eventRoot(root),
33  system(sys),
34  controller(c),
35  mode(SINGLE)
36  {
37  eventRoot->ref();
39  sel_assocobjs_click->setName("sel_assocobjs_click");
40  sel_assocobjs_click->ref();
42  sel_assocobjs_click->policy = SoCooperativeSelection::SINGLE;
43  sys->registerSelectionNode(sel_assocobjs_click);
44 
46  sel_assocobjs->setName("sel_assocobjs");
47  sel_assocobjs->ref();
49  sel_assocobjs_click->policy = SoCooperativeSelection::SINGLE;
50  sys->registerSelectionNode(sel_assocobjs);
51 
53  root->addChild(sel_assocobjs);
54  }

◆ Imp() [2/2]

AscObjSelectionManager::Imp::Imp ( const Imp )
delete

◆ ~Imp()

AscObjSelectionManager::Imp::~Imp ( )
inline

Definition at line 57 of file AscObjSelectionManager.cxx.

58  {
60  sel_assocobjs_click->unref();
61  sel_assocobjs->unref();
62  eventRoot->unref();
63  }

Member Function Documentation

◆ ascObjHandle() [1/2]

AssociatedObjectHandleBase * AscObjSelectionManager::Imp::ascObjHandle ( const SoPath *  path)

Definition at line 187 of file AscObjSelectionManager.cxx.

188 {
189  const int n(path?path->getLength():0);
190  AssociatedObjectHandleBase * handle(nullptr);
191  for (int i = 0; i < n; ++i) {
192  if (path->getNodeFromTail(i)->getTypeId()==SoSeparator::getClassTypeId()) {
193  handle = ascObjHandle(static_cast<SoSeparator*>(path->getNodeFromTail(i)));
194  if (handle)
195  return handle;
196  }
197  }
198  return nullptr;
199 }

◆ ascObjHandle() [2/2]

AssociatedObjectHandleBase * AscObjSelectionManager::Imp::ascObjHandle ( const SoSeparator *  s)

Definition at line 202 of file AscObjSelectionManager.cxx.

203 {
204  std::map<SoSeparator*,AssociatedObjectHandleBase*>::const_iterator
205  it(ascobjs_simpleToHandle.find(const_cast<SoSeparator*>(s)));
206  if (it!=ascobjs_simpleToHandle.end())
207  return it->second;
208  it = ascobjs_detailedToHandle.find(const_cast<SoSeparator*>(s));
209  return it==ascobjs_detailedToHandle.end() ? 0 : it->second;
210 }

◆ operator=()

Imp& AscObjSelectionManager::Imp::operator= ( const Imp )
delete

◆ shiftIsDown()

static bool AscObjSelectionManager::Imp::shiftIsDown ( )
inlinestatic

Definition at line 82 of file AscObjSelectionManager.cxx.

82 { return Qt::ShiftModifier & QApplication::keyboardModifiers(); }

◆ updateSelectionVisuals()

void AscObjSelectionManager::Imp::updateSelectionVisuals ( )

Definition at line 213 of file AscObjSelectionManager.cxx.

214 {
215  const bool isSimpleMode = controller->assocObjDetailLevel()==TrackCommonFlags::SIMPLE;
216  sel_assocobjs->deselectAll();
218  SoPath * path = new SoPath(sel_assocobjs);
219  path->ref();
221  (isSimpleMode?handle->shapeSimple():handle->shapeDetailed()))) {
222  theclass->message("updateSelectionVisuals ERROR: Failed to relocate picked node.");
223  path->unref();
224  continue;
225  }
226  sel_assocobjs->select(path);
227  path->unref();
228  }
229 }

Member Data Documentation

◆ ascobjs_detailedToHandle

std::map<SoSeparator*,AssociatedObjectHandleBase*> AscObjSelectionManager::Imp::ascobjs_detailedToHandle

Definition at line 74 of file AscObjSelectionManager.cxx.

◆ ascobjs_simpleToHandle

std::map<SoSeparator*,AssociatedObjectHandleBase*> AscObjSelectionManager::Imp::ascobjs_simpleToHandle

Definition at line 73 of file AscObjSelectionManager.cxx.

◆ controller

TrackSystemController* AscObjSelectionManager::Imp::controller

Definition at line 68 of file AscObjSelectionManager.cxx.

◆ eventRoot

SoSeparator* AscObjSelectionManager::Imp::eventRoot

Definition at line 66 of file AscObjSelectionManager.cxx.

◆ mode

MODE AscObjSelectionManager::Imp::mode

Definition at line 69 of file AscObjSelectionManager.cxx.

◆ sel_assocobjs

SoCooperativeSelection* AscObjSelectionManager::Imp::sel_assocobjs

Definition at line 71 of file AscObjSelectionManager.cxx.

◆ sel_assocobjs_click

SoCooperativeSelection* AscObjSelectionManager::Imp::sel_assocobjs_click

Definition at line 70 of file AscObjSelectionManager.cxx.

◆ selAscObjHandles

QList<AssociatedObjectHandleBase*> AscObjSelectionManager::Imp::selAscObjHandles

Definition at line 79 of file AscObjSelectionManager.cxx.

◆ system

IVP13DSystem* AscObjSelectionManager::Imp::system

Definition at line 67 of file AscObjSelectionManager.cxx.

◆ theclass

AscObjSelectionManager* AscObjSelectionManager::Imp::theclass

Definition at line 65 of file AscObjSelectionManager.cxx.


The documentation for this class was generated from the following file:
SoCooperativeSelection::INERT
@ INERT
Definition: SoCooperativeSelection.h:41
AssociatedObjectHandleBase
Definition: AssociatedObjectHandleBase.h:35
AscObjSelectionManager::Imp::system
IVP13DSystem * system
Definition: AscObjSelectionManager.cxx:67
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
athena.path
path
python interpreter configuration --------------------------------------—
Definition: athena.py:128
TrackCommonFlags::SIMPLE
@ SIMPLE
Definition: TrackCommonFlags.h:39
AscObjSelectionManager::Imp::ascObjHandle
AssociatedObjectHandleBase * ascObjHandle(const SoPath *)
Definition: AscObjSelectionManager.cxx:187
AscObjSelectionManager::Imp::selAscObjHandles
QList< AssociatedObjectHandleBase * > selAscObjHandles
Definition: AscObjSelectionManager.cxx:79
AscObjSelectionManager::Imp::sel_assocobjs_click
SoCooperativeSelection * sel_assocobjs_click
Definition: AscObjSelectionManager.cxx:70
AscObjSelectionManager::SINGLE
@ SINGLE
Definition: AscObjSelectionManager.h:52
SoCooperativeSelection::activePolicy
SoSFEnum activePolicy
Definition: SoCooperativeSelection.h:49
skel.it
it
Definition: skel.GENtoEVGEN.py:396
TrackSystemController::assocObjDetailLevel
TrackCommonFlags::DETAILLEVEL assocObjDetailLevel() const
Definition: TrackSystemController.cxx:1764
sendEI_SPB.root
root
Definition: sendEI_SPB.py:34
mapkey::sys
@ sys
Definition: TElectronEfficiencyCorrectionTool.cxx:42
AscObjSelectionManager::Imp::ascobjs_simpleToHandle
std::map< SoSeparator *, AssociatedObjectHandleBase * > ascobjs_simpleToHandle
Definition: AscObjSelectionManager.cxx:73
lumiFormat.i
int i
Definition: lumiFormat.py:85
beamspotman.n
n
Definition: beamspotman.py:731
AscObjSelectionManager::Imp::theclass
AscObjSelectionManager * theclass
Definition: AscObjSelectionManager.cxx:65
AscObjSelectionManager::Imp::eventRoot
SoSeparator * eventRoot
Definition: AscObjSelectionManager.cxx:66
SoCooperativeSelection::ACTIVE
@ ACTIVE
Definition: SoCooperativeSelection.h:41
AscObjSelectionManager::Imp::controller
TrackSystemController * controller
Definition: AscObjSelectionManager.cxx:68
IVP13DSystem::unregisterSelectionNode
void unregisterSelectionNode(SoCooperativeSelection *)
Definition: IVP13DSystem.cxx:281
AscObjSelectionManager::Imp::mode
MODE mode
Definition: AscObjSelectionManager.cxx:69
VP1HelperClassBase::message
void message(const QString &) const
Definition: VP1HelperClassBase.cxx:49
AscObjSelectionManager::Imp::ascobjs_detailedToHandle
std::map< SoSeparator *, AssociatedObjectHandleBase * > ascobjs_detailedToHandle
Definition: AscObjSelectionManager.cxx:74
python.compressB64.c
def c
Definition: compressB64.py:93
AscObjSelectionManager::Imp::sel_assocobjs
SoCooperativeSelection * sel_assocobjs
Definition: AscObjSelectionManager.cxx:71
VP1QtInventorUtils::changePathTail
static bool changePathTail(SoPath *path, SoNode *commonBranchPoint, SoNode *newtail)
Definition: VP1QtInventorUtils.cxx:1348
SoCooperativeSelection
Definition: SoCooperativeSelection.h:29