Changeset 2897 for trunk/MagicSoft/Mars
- Timestamp:
- 01/23/04 18:23:44 (21 years ago)
- Location:
- trunk/MagicSoft/Mars/mbase
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mbase/MStatusDisplay.cc
r2893 r2897 805 805 // -------------------------------------------------------------------------- 806 806 // 807 // This function was connected to all created canvases. It is used 808 // to redirect GetObjectInfo into our own status bar. 809 // 810 // The 'connection' is done in AddTab 811 // 812 void MStatusDisplay::EventInfo(Int_t event, Int_t px, Int_t py, TObject *selected) 813 { 814 // Writes the event status in the status bar parts 815 if (!selected) 816 return; 817 818 TCanvas *c = (TCanvas *)gTQSender; 819 820 TVirtualPad* save=gPad; 821 822 gPad = c->GetSelectedPad(); 823 824 SetStatusLine2(selected->GetObjectInfo(px,py)); 825 826 gPad=save; 827 } 828 829 // -------------------------------------------------------------------------- 830 // 807 831 // Adds a new tab with the name 'name'. Adds a TRootEmbeddedCanvas to the 808 832 // tab and returns a reference to the corresponding TCanvas. … … 834 858 if (TestBit(kNoContextMenu)) 835 859 c.SetBit(kNoContextMenu); 860 861 // Connect all TCanvas::ProcessedEvent to this->EventInfo 862 // This means, that after TCanvas has processed an event 863 // EventInfo of this class is called, see TCanvas::HandleInput 864 c.ConnectToClass("ProcessedEvent(Int_t,Int_t,Int_t,TObject*)", 865 "MStatusDisplay", this, "EventInfo(Int_t,Int_t,Int_t,TObject*)"); 836 866 837 867 // layout and map new tab -
trunk/MagicSoft/Mars/mbase/MStatusDisplay.h
r2805 r2897 196 196 Bool_t CheckTabForCanvas(int num) const; 197 197 198 void EventInfo(Int_t event, Int_t px, Int_t py, TObject *selected); 199 198 200 ClassDef(MStatusDisplay, 0) // Window for a status display 199 201 };
Note:
See TracChangeset
for help on using the changeset viewer.