# SoTabBoxDragger.h

    00001 #ifndef COIN_SOTABBOXDRAGGER_H
    00002 #define COIN_SOTABBOXDRAGGER_H
    00003
    00004 /**************************************************************************\
    00005  *
    00006  *  This file is part of the Coin 3D visualization library.
    00007  *  Copyright (C) 1998-2003 by Systems in Motion.  All rights reserved.
    00008  *
    00009  *  This library is free software; you can redistribute it and/or
    00010  *  modify it under the terms of the GNU General Public License
    00011  *  ("GPL") version 2 as published by the Free Software Foundation.
    00012  *  See the file LICENSE.GPL at the root directory of this source
    00013  *  distribution for additional information about the GNU GPL.
    00014  *
    00015  *  For using Coin with software that can not be combined with the GNU
    00016  *  GPL, and for taking advantage of the additional benefits of our
    00017  *  support services, please contact Systems in Motion about acquiring
    00018  *  a Coin Professional Edition License.
    00019  *
    00020  *  See <URL:http://www.coin3d.org> for  more information.
    00021  *
    00022  *  Systems in Motion, Teknobyen, Abels Gate 5, 7030 Trondheim, NORWAY.
    00023  *  <URL:http://www.sim.no>.
    00024  *
    00025 \**************************************************************************/
    00026
    00027 #include <Inventor/draggers/SoDragger.h>
    00028 #include <Inventor/fields/SoSFVec3f.h>
    00029
    00030 class SoSensor;
    00031 class SoFieldSensor;
    00032
    00033
    00034 class COIN_DLL_API SoTabBoxDragger : public SoDragger {
    00035   typedef SoDragger inherited;
    00036
    00037   SO_KIT_HEADER(SoTabBoxDragger);
    00038
    00039   SO_KIT_CATALOG_ENTRY_HEADER(boxGeom);
    00040   SO_KIT_CATALOG_ENTRY_HEADER(surroundScale);
    00041   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane1);
    00042   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane1Sep);
    00043   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane1Xf);
    00044   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane2);
    00045   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane2Sep);
    00046   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane2Xf);
    00047   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane3);
    00048   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane3Sep);
    00049   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane3Xf);
    00050   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane4);
    00051   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane4Sep);
    00052   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane4Xf);
    00053   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane5);
    00054   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane5Sep);
    00055   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane5Xf);
    00056   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane6);
    00057   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane6Sep);
    00058   SO_KIT_CATALOG_ENTRY_HEADER(tabPlane6Xf);
    00059
    00060
    00061 public:
    00062   static void initClass(void);
    00063   SoTabBoxDragger(void);
    00064
    00065   SoSFVec3f translation;
    00066   SoSFVec3f scaleFactor;
    00067
    00068   void adjustScaleTabSize(void);
    00069
    00070 protected:
    00071   ~SoTabBoxDragger();
    00072   virtual SbBool setUpConnections(SbBool onoff, SbBool doitalways = FALSE);
    00073   virtual void setDefaultOnNonWritingFields(void);
    00074
    00075   static void invalidateSurroundScaleCB(void * f, SoDragger * d);
    00076   static void fieldSensorCB(void * f, SoSensor * s);
    00077   static void valueChangedCB(void * f, SoDragger * d);
    00078
    00079   SoFieldSensor * translFieldSensor;
    00080   SoFieldSensor * scaleFieldSensor;
    00081
    00082 private:
    00083   void initTransformNodes(void);
    00084 };
    00085
    00086 #endif // !COIN_SOTABBOXDRAGGER_H