src/widget/widget_button_img.cpp
branchcpp_gui
changeset 6290 8078f7a3c8a0
parent 6289 be3d8bd9fb02
equal deleted inserted replaced
6289:be3d8bd9fb02 6290:8078f7a3c8a0
    16 #include "../genworld.h"
    16 #include "../genworld.h"
    17 #include "../helpers.hpp"
    17 #include "../helpers.hpp"
    18 #include "window_events.hpp"
    18 #include "window_events.hpp"
    19 #include "widget_types.h"
    19 #include "widget_types.h"
    20 
    20 
       
    21 namespace gui {
    21 
    22 
       
    23 /*virtual*/ void ImageButton::OnPaint(EvtPaint &e)
       
    24 {
       
    25 	DrawBackground(e);
       
    26 	Point16 pos = m_sprite_offset + (m_pushed ? Point16(3, 3) : Point16(2, 2));
       
    27 	DrawSprite(m_sprite, PAL_NONE, pos);
       
    28 }
       
    29 
       
    30 } // namespace gui