// @(#)root/eve:$Id$
// Authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007

/*************************************************************************
 * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#ifndef ROOT_TEveTransEditor
#define ROOT_TEveTransEditor

#include "TGedFrame.h"

class TGCheckButton;
class TGTextButton;

class TEveTrans;
class TEveGTriVecValuator;


class TEveTransSubEditor : public TGVerticalFrame
{
   TEveTransSubEditor(const TEveTransSubEditor&);            // Not implemented
   TEveTransSubEditor& operator=(const TEveTransSubEditor&); // Not implemented

protected:
   TEveTrans            *fTrans;

   TGHorizontalFrame    *fTopHorFrame;

   TGCheckButton        *fUseTrans;
   TGCheckButton        *fEditTrans;

   TGVerticalFrame      *fEditTransFrame;

   TEveGTriVecValuator  *fPos;
   TEveGTriVecValuator  *fRot;
   TEveGTriVecValuator  *fScale;

   TGCheckButton        *fAutoUpdate;
   TGTextButton         *fUpdate;

public:
   TEveTransSubEditor(TGWindow* p);
   virtual ~TEveTransSubEditor() {}

   void SetModel(TEveTrans* t);
   void SetTransFromData();

   void UseTrans();     //*SIGNAL*
   void TransChanged(); //*SIGNAL*

   void DoUseTrans();
   void DoEditTrans();
   void DoTransChanged();

   TEveGTriVecValuator*  GetPosValuator(){ return fPos;}
   TEveGTriVecValuator*  GetRotValuator(){ return fRot;}
   TEveGTriVecValuator*  GetScaleValuator(){ return fScale;}

   ClassDef(TEveTransSubEditor, 0); // Sub-editor for TEveTrans class.
};


class TEveTransEditor : public TGedFrame
{
private:
   TEveTransEditor(const TEveTransEditor&);            // Not implemented
   TEveTransEditor& operator=(const TEveTransEditor&); // Not implemented

protected:
   TEveTrans          *fM;  // Model object.
   TEveTransSubEditor *fSE; // Actual editor widget.

public:
   TEveTransEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground());
   virtual ~TEveTransEditor() {}

   virtual void SetModel(TObject* obj);

   ClassDef(TEveTransEditor, 1); // Editor for TEveTrans class.
};

#endif
 TEveTransEditor.h:1
 TEveTransEditor.h:2
 TEveTransEditor.h:3
 TEveTransEditor.h:4
 TEveTransEditor.h:5
 TEveTransEditor.h:6
 TEveTransEditor.h:7
 TEveTransEditor.h:8
 TEveTransEditor.h:9
 TEveTransEditor.h:10
 TEveTransEditor.h:11
 TEveTransEditor.h:12
 TEveTransEditor.h:13
 TEveTransEditor.h:14
 TEveTransEditor.h:15
 TEveTransEditor.h:16
 TEveTransEditor.h:17
 TEveTransEditor.h:18
 TEveTransEditor.h:19
 TEveTransEditor.h:20
 TEveTransEditor.h:21
 TEveTransEditor.h:22
 TEveTransEditor.h:23
 TEveTransEditor.h:24
 TEveTransEditor.h:25
 TEveTransEditor.h:26
 TEveTransEditor.h:27
 TEveTransEditor.h:28
 TEveTransEditor.h:29
 TEveTransEditor.h:30
 TEveTransEditor.h:31
 TEveTransEditor.h:32
 TEveTransEditor.h:33
 TEveTransEditor.h:34
 TEveTransEditor.h:35
 TEveTransEditor.h:36
 TEveTransEditor.h:37
 TEveTransEditor.h:38
 TEveTransEditor.h:39
 TEveTransEditor.h:40
 TEveTransEditor.h:41
 TEveTransEditor.h:42
 TEveTransEditor.h:43
 TEveTransEditor.h:44
 TEveTransEditor.h:45
 TEveTransEditor.h:46
 TEveTransEditor.h:47
 TEveTransEditor.h:48
 TEveTransEditor.h:49
 TEveTransEditor.h:50
 TEveTransEditor.h:51
 TEveTransEditor.h:52
 TEveTransEditor.h:53
 TEveTransEditor.h:54
 TEveTransEditor.h:55
 TEveTransEditor.h:56
 TEveTransEditor.h:57
 TEveTransEditor.h:58
 TEveTransEditor.h:59
 TEveTransEditor.h:60
 TEveTransEditor.h:61
 TEveTransEditor.h:62
 TEveTransEditor.h:63
 TEveTransEditor.h:64
 TEveTransEditor.h:65
 TEveTransEditor.h:66
 TEveTransEditor.h:67
 TEveTransEditor.h:68
 TEveTransEditor.h:69
 TEveTransEditor.h:70
 TEveTransEditor.h:71
 TEveTransEditor.h:72
 TEveTransEditor.h:73
 TEveTransEditor.h:74
 TEveTransEditor.h:75
 TEveTransEditor.h:76
 TEveTransEditor.h:77
 TEveTransEditor.h:78
 TEveTransEditor.h:79
 TEveTransEditor.h:80
 TEveTransEditor.h:81
 TEveTransEditor.h:82
 TEveTransEditor.h:83
 TEveTransEditor.h:84
 TEveTransEditor.h:85
 TEveTransEditor.h:86
 TEveTransEditor.h:87