Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #pragma once
00025
00026 #include "cinder/app/AppScreenSaver.h"
00027 #include "cinder/app/AppImplMsw.h"
00028 #include "cinder/app/AppImplMswRenderer.h"
00029 #include <windows.h>
00030 #undef min
00031 #undef max
00032
00033 namespace cinder { namespace app {
00034
00035 class WindowImplMswScreenSaver;
00036
00037 class AppImplMswScreenSaver : public AppImplMsw {
00038 public:
00039 AppImplMswScreenSaver( class AppScreenSaver *aApp );
00040 virtual ~AppImplMswScreenSaver() {}
00041
00042 void init( HWND aWnd );
00043 void run();
00044 void quit() {}
00045
00046 LRESULT eventHandler( HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam );
00047
00048 virtual WindowRef getWindow() const;
00050 virtual size_t getNumWindows() const;
00052 virtual WindowRef getWindowIndex( size_t index ) const;
00053
00054 bool isPreview() const;
00055
00056
00057 virtual void closeWindow( class WindowImplMsw *windowImpl ) {}
00058
00059 virtual void setForegroundWindow( WindowRef window ) {}
00060
00061 protected:
00062 class AppScreenSaver *mApp;
00063 bool mPreview;
00064 bool mDebugMode;
00065 std::list<WindowImplMswScreenSaver*> mWindows;
00066 std::list<BlankingWindowRef> mBlankingWindows;
00067 };
00068
00069 class WindowImplMswScreenSaver : public WindowImplMsw {
00070 public:
00071 WindowImplMswScreenSaver( HWND hwnd, RendererRef renderer, RendererRef sharedRenderer, AppImplMswScreenSaver *appImpl )
00072 : WindowImplMsw( hwnd, renderer, sharedRenderer, appImpl ) {}
00073
00074
00075 virtual void setFullScreen( bool fullScreen, const app::FullScreenOptions &options );
00076
00077 protected:
00078 friend AppImplMswScreenSaver;
00079 };
00080
00081
00082 } }