]> git.uio.no Git - u/mrichter/AliRoot.git/blame - EVE/Reve/RGEditor.cxx
Add getter for fValueIsColor.
[u/mrichter/AliRoot.git] / EVE / Reve / RGEditor.cxx
CommitLineData
5a5a1232 1// $Header$
2
3#include "RGEditor.h"
a8600b56 4#include "RenderElement.h"
5#include "RGTopFrame.h"
5a5a1232 6
7#include <TGedFrame.h>
8#include <TGCanvas.h>
9#include <TCanvas.h>
10
11//______________________________________________________________________
12// RGEditor
13//
14
15using namespace Reve;
16
17ClassImp(RGEditor)
18
3c67f72c 19RGEditor::RGEditor(TCanvas* canvas) :
20 TGedEditor(canvas),
21 fRnrElement(0)
5a5a1232 22{}
23
a8600b56 24void RGEditor::DisplayRenderElement(RenderElement* re)
25{
26 fRnrElement = re;
27 TObject* obj = fRnrElement ? fRnrElement->GetObject() : 0;
28 SetModel(fPad, obj, kButton1Down);
29}
30
5a5a1232 31void RGEditor::DisplayObject(TObject* obj)
32{
a8600b56 33 fRnrElement = 0;
34 SetModel(fPad, obj, kButton1Down);
35}
36
37void RGEditor::Update(TGedFrame* /*gframe*/)
38{
39 // Virtual method from TGedEditor ... called on every change.
0de797f2 40
a8600b56 41 if (fRnrElement) {
42 fRnrElement->UpdateItems();
e8f20a25 43 }
a8600b56 44
45 gReve->Redraw3D();
5a5a1232 46}