Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

cybwinmouse2scriptc.h

Go to the documentation of this file.
00001 /*
00002 Copyright (C) 1999  Carsten Winkelholz
00003 
00004 Address:  FGAN Forschungsgesellschaft für Angewandte Naturwissenschaften e. V.
00005       Neuenahrer Str. 20
00006       D - 53343 Wachtberg
00007       
00008 Email:    winkelholz@fgan.de
00009 
00010 This program is free software; you can redistribute it and/or
00011 modify it under the terms of the GNU General Public License
00012 as published by the Free Software Foundation; either version 2
00013 of the License, or (at your option) any later version.
00014 
00015 This program is distributed in the hope that it will be useful,
00016 but WITHOUT ANY WARRANTY; without even the implied warranty of
00017 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00018 GNU General Public License for more details.
00019 
00020 You should have received a copy of the GNU General Public License
00021 along with this program; if not, write to the Free Software
00022 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
00023 */
00024 
00025 
00026 #ifndef CybWinMouse2ScriptC_H
00027 #define CybWinMouse2ScriptC_H
00028 
00029 
00030 #include "oaw/ctk/cybviewc.h"
00031 #include "oaw/ctk/cybviewpointsensorc.h"
00032 #include "oaw/win/wndc.h"
00033 #include "../oawconfig.h"
00034 
00035 OAW_BEGIN_NAMESPACE
00036 
00037 class CybScriptC;
00038 class CybGraphicChannelC;
00039 
00040 class OAW_DLLMAPPING CybWinMouse2ScriptC 
00041 {
00042 public:
00043   CybWinMouse2ScriptC(CybWorldC*,CybGraphicChannelC*);
00044 
00045   void Button(int bnr,int state, int x, int y);
00046   void Motion(int x,int y);
00047   void KeyPressed(char ch);
00048 
00049   void SetScript(CybScriptC*);
00050   void SetWindowSize(long w, long h){m_winWidth=w;m_winHeight=h;}
00051 
00052 protected:
00053   void CalcMousePos(int iX, int iY,VectorC&,VectorC&,SFRotation&);
00054   
00055 protected:
00056 
00057   CybWorldC* m_pWorld;
00058   CybGraphicChannelC* m_pChannel_mouse;
00059   CybScriptC* m_pScriptWinEvents;
00060   long m_winEventsKeyID;
00061   long m_winEventsMousePosID;
00062   long m_winEventsMouseDirID;
00063   long m_winEventsMouseOriID;
00064   long m_winEventsMouseButtonID;
00065   long m_winMousePosX_alt;
00066   long m_winMousePosY_alt;
00067   SFBool m_bMouseLogOn;
00068   long m_winWidth,m_winHeight;
00069 };
00070 
00071 OAW_END_NAMESPACE
00072 
00073 #endif
00074 
00075 
00076 
00077 
00078 
00079 
00080 

Generated on Tue Jul 29 14:24:14 2003 for Open ActiveWrl by doxygen1.3-rc2