]> git.tdb.fi Git - libs/gui.git/blobdiff - source/graphics/display.h
Move struct VideoMode to its own header
[libs/gui.git] / source / graphics / display.h
index 83b18532148c6cc01cafa9547539e9ec80091fa0..370bf0dea81013c03d2212ae77e2cfabd9cb7981 100644 (file)
@@ -2,34 +2,15 @@
 #define MSP_GRAPHICS_DISPLAY_H_
 
 #include <list>
-#include <map>
 #include <stdexcept>
 #include <string>
+#include "videomode.h"
 
 namespace Msp {
 namespace Graphics {
 
 class Window;
 
-struct VideoMode
-{
-       unsigned width;
-       unsigned height;
-       unsigned rate;
-
-       VideoMode(): width(0), height(0), rate(0) { }
-       VideoMode(unsigned w, unsigned h): width(w), height(h), rate(0) { }
-};
-
-
-class unsupported_video_mode: public std::runtime_error
-{
-public:
-       unsupported_video_mode(const VideoMode &);
-       virtual ~unsupported_video_mode() throw () { }
-};
-
-
 class Display
 {
 public:
@@ -55,6 +36,9 @@ public:
        void restore_mode() { set_mode(orig_mode); }
 
        void tick();
+private:
+       bool process_events();
+public:
        void check_error();
 };