Mercurial > hg > easaier-soundaccess
view data/model/SDLWidget.h @ 162:faafebcf67a2
new colors
author | benoitrigolleau |
---|---|
date | Thu, 15 Nov 2007 16:48:50 +0000 |
parents | f2d2c1084e7c |
children | 2ac52ea3c1c4 |
line wrap: on
line source
#ifndef _SDL_WIDGET_H #define _SDL_WIDGET_H #include <QWidget> #include <QShowEvent> #include <QTimer> #ifdef WIN32 #include <SDL.h> #endif #ifdef __unix__ #include <SDL/SDL.h> #endif #undef main class SDLWidget : public QWidget { Q_OBJECT public: SDLWidget(); virtual ~SDLWidget(); void setInitSize(int w, int h); signals: void sizeChanged(int w, int h); void zoomfactorChanged(float factor); void initSizeChanged(); public slots: void setZoomFactor( float ); void wheelEvent( QWheelEvent* ); protected: bool windowInitialized; SDL_Surface *screen; int m_width; int m_height; virtual void showEvent(QShowEvent *e); protected slots: void updateMinSize(); private: float m_zoomFactor; }; #endif