src/Graphics/Display.hh
branchnew_graphics
changeset 413 7dddc163489a
parent 412 721c60072091
child 414 cede5463b845
equal deleted inserted replaced
412:721c60072091 413:7dddc163489a
    20 
    20 
    21 class Display;
    21 class Display;
    22 
    22 
    23 }
    23 }
    24 
    24 
    25 #include "Drawable.hh"
    25 #include "View.hh"
    26 #include "../Timer.hh"
    26 #include "../Timer.hh"
    27 
    27 
    28 #include <ClanLib/display.h>
    28 #include <ClanLib/display.h>
    29 
    29 
    30 namespace graphics
    30 namespace graphics
    51     Timer update_timer;
    51     Timer update_timer;
    52 
    52 
    53     /**
    53     /**
    54      * What we draw
    54      * What we draw
    55      */
    55      */
    56     Drawable *target;
    56     View *current_view;
    57 
    57 
    58     CL_SlotContainer slots;
    58     CL_SlotContainer slots;
    59 
    59 
    60 public:
    60 public:
    61     /**
    61     /**
    83     PixelCoordinate getResolution (void) { 
    83     PixelCoordinate getResolution (void) { 
    84         return PixelCoordinate(get_width(), get_height());
    84         return PixelCoordinate(get_width(), get_height());
    85     }
    85     }
    86 
    86 
    87     /**
    87     /**
    88      * Set draw target
    88      * Display the given view, this will initialize resize it to the right size
    89      */
    89      */
    90     void setTarget (Drawable *target) {
    90     void setView (View *view);
    91         this->target = target;
       
    92     }
       
    93 
    91 
    94     /**
    92     /**
    95      * Shift back and forth between fullscreen and windowed mode, retaining resolutions
    93      * Shift back and forth between fullscreen and windowed mode, retaining resolutions
    96      */
    94      */
    97     void toggle_fullscreen (void);
    95     void toggle_fullscreen (void);