CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Public Attributes | Private Member Functions
FWGLEventHandler Class Reference

#include <FWGLEventHandler.h>

Inheritance diagram for FWGLEventHandler:

Public Member Functions

 FWGLEventHandler (TGWindow *w, TObject *obj, TEveCaloLego *l=0)
 
virtual Bool_t HandleKey (Event_t *event)
 
virtual void PopupContextMenu (TGLPhysicalShape *pshp, Event_t *event, Int_t gx, Int_t gy)
 
virtual ~FWGLEventHandler ()
 

Public Attributes

sigc::signal< void, Int_t, Int_t > openSelectedModelContextMenu_
 

Private Member Functions

 FWGLEventHandler (const FWGLEventHandler &)
 
const FWGLEventHandleroperator= (const FWGLEventHandler &)
 

Detailed Description

Definition at line 10 of file FWGLEventHandler.h.

Constructor & Destructor Documentation

FWGLEventHandler::FWGLEventHandler ( TGWindow *  w,
TObject *  obj,
TEveCaloLego *  l = 0 
)

Definition at line 10 of file FWGLEventHandler.cc.

10  :
11  TEveLegoEventHandler(w, obj, l)
12 {
13 }
tuple obj
Example code starts here #.
Definition: VarParsing.py:655
virtual FWGLEventHandler::~FWGLEventHandler ( )
inlinevirtual

Definition at line 14 of file FWGLEventHandler.h.

14 {}
FWGLEventHandler::FWGLEventHandler ( const FWGLEventHandler )
private

Member Function Documentation

Bool_t FWGLEventHandler::HandleKey ( Event_t *  event)
virtual

Definition at line 34 of file FWGLEventHandler.cc.

References event(), PopupContextMenu(), tmp, x, and detailsBasic3DVector::y.

35 {
36  UInt_t keysym;
37  char tmp[2];
38  gVirtualX->LookupString(event, tmp, sizeof(tmp), keysym);
39 
40  if (keysym == kKey_Enter || keysym == kKey_Return || keysym == kKey_Space)
41  {
42  if (event->fType == kGKeyPress)
43  {
44  Int_t x, y;
45  Window_t childdum;
46  gVirtualX->TranslateCoordinates(fGLViewer->GetGLWidget()->GetId(), gClient->GetDefaultRoot()->GetId(),
47  event->fX, event->fY, x, y, childdum);
48 
49  fGLViewer->RequestSelect(event->fX, event->fY);
50  PopupContextMenu(fGLViewer->GetSelRec().GetPhysShape(), event, x, y);
51  }
52  return kTRUE;
53  }
54  else
55  {
56  return TEveLegoEventHandler::HandleKey(event);
57  }
58 }
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
unsigned int UInt_t
Definition: FUTypes.h:12
virtual void PopupContextMenu(TGLPhysicalShape *pshp, Event_t *event, Int_t gx, Int_t gy)
std::vector< std::vector< double > > tmp
Definition: MVATrainer.cc:100
Definition: DDAxes.h:10
const FWGLEventHandler& FWGLEventHandler::operator= ( const FWGLEventHandler )
private
void FWGLEventHandler::PopupContextMenu ( TGLPhysicalShape *  pshp,
Event_t *  event,
Int_t  gx,
Int_t  gy 
)
virtual

Definition at line 16 of file FWGLEventHandler.cc.

References openSelectedModelContextMenu_.

Referenced by HandleKey().

17 {
18  // Popup context menu.
19 
20 
21  if (event->fState & kKeyShiftMask && event->fState & kKeyControlMask)
22  {
23  TGLEventHandler::PopupContextMenu(pshp, event, gx, gy);
24  return;
25  }
26 
27  if (pshp)
28  {
29  SelectForClicked(event);
31  }
32 }
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
sigc::signal< void, Int_t, Int_t > openSelectedModelContextMenu_

Member Data Documentation

sigc::signal<void,Int_t,Int_t> FWGLEventHandler::openSelectedModelContextMenu_

Definition at line 20 of file FWGLEventHandler.h.

Referenced by FWEveView::FWEveView(), and PopupContextMenu().