Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

screen.h

Go to the documentation of this file.
00001 /* ***********************************************************************************
00002         Writer:         Sebastien Bloc
00003         Copyright:      2003-2004
00004         eMail:          sebastien.bloc@free.fr
00005         URL:            http://mignonsoft.free.fr
00006 
00007         This program is free software; you can redistribute it and/or
00008         modify it under the terms of the GNU General Public License
00009         as published by the Free Software Foundation; either version 2
00010         of the License, or (at your option) any later version.
00011 
00012         This program is distributed in the hope that it will be useful,
00013         but WITHOUT ANY WARRANTY; without even the implied warranty of
00014         MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015         GNU General Public License for more details.
00016         http://www.gnu.org/copyleft/gpl.html
00017 *********************************************************************************** */
00018 
00023 #ifndef INCLUDE_SCREEN_H
00024 #define INCLUDE_SCREEN_H
00025 
00026 #include <windows.h>
00027 #include "myString.h"
00028 #include "region.h"
00029 
00030 class Screen
00031 {
00032 private:
00033         HWND hWndInsertAfter;
00034         HINSTANCE hInst;
00035         MyString title;
00036         MyString className;
00037         BOOL enableFullScreenOld;
00038 
00039         int xNormal;
00040         int yNormal;
00041         int dxClient;
00042         int dyClient;
00043         int dxFull;
00044         int dyFull;
00045         int dxWC;
00046         int dyWC;
00047 
00048         DWORD dwExStyle;
00049         DWORD dwStyle;
00050 
00051         void Adjust();
00052         void ComputeDeltaClientToWindow();
00053 
00054 public:
00055         HDC       hDC;                                  
00056         HGLRC hGLRC;                            
00057 
00058         BOOL enableTitle;
00059         BOOL enableFullScreen;
00060 
00061         int dxNormal;
00062         int dyNormal;
00063 
00064         HWND hWnd;
00065         Region region;  
00066 
00067         // init
00068         Screen();
00069         ~Screen();
00070         BOOL Setup(WNDCLASS *wc,char *_className,char *_title);
00071         BOOL Create(HINSTANCE hInstance);
00072         void Destroy();
00073         void Show(BOOL enable);
00074         void Update(BOOL applySize);
00075         void SetSize(int dx,int dy,BOOL always);
00076 
00077         void BindOpenGL(BOOL useAccumulation);
00078         BOOL SwapBuffers();
00079 
00080         // modes
00081         void SetTopMost();
00082         void SetTitle(char *_title);
00083         void SetFullScreen();
00084         
00085         // styles
00086         void ApplyStyles();
00087         void ApplyStyle();
00088         void ApplyStyleEx();
00089         void ChangeStyle(int set,DWORD dwStyleChange);
00090         void ChangeStyleEx(int set,DWORD dwStyleChange);
00091         void SetStyle(DWORD _dwStyle);
00092         void MsgInfoType();
00093         void ApplySize();
00094 
00095         // region
00096         void RegionReset();
00097         void RegionUse();
00098 };
00099 #endif

Generated on Fri Aug 20 19:19:49 2004 for 3d Controls by doxygen 1.3.6