mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-17 22:03:24 +00:00
parent
673c1fa4d9
commit
8279602d70
@ -171,6 +171,7 @@ private:
|
|||||||
/** Fires a draw event. */
|
/** Fires a draw event. */
|
||||||
using events::sdl_handler::draw;
|
using events::sdl_handler::draw;
|
||||||
void draw();
|
void draw();
|
||||||
|
void draw_everything();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Fires a video resize event.
|
* Fires a video resize event.
|
||||||
@ -381,8 +382,9 @@ void sdl_event_handler::handle_event(const SDL_Event& event)
|
|||||||
case DRAW_EVENT:
|
case DRAW_EVENT:
|
||||||
draw();
|
draw();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case DRAW_ALL_EVENT:
|
case DRAW_ALL_EVENT:
|
||||||
draw();
|
draw_everything();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case TIMER_EVENT:
|
case TIMER_EVENT:
|
||||||
@ -540,6 +542,15 @@ void sdl_event_handler::draw()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void sdl_event_handler::draw_everything()
|
||||||
|
{
|
||||||
|
for(auto dispatcher : dispatchers_) {
|
||||||
|
dynamic_cast<widget&>(*dispatcher).set_is_dirty(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
draw();
|
||||||
|
}
|
||||||
|
|
||||||
void sdl_event_handler::video_resize(const point& new_size)
|
void sdl_event_handler::video_resize(const point& new_size)
|
||||||
{
|
{
|
||||||
DBG_GUI_E << "Firing: " << SDL_VIDEO_RESIZE << ".\n";
|
DBG_GUI_E << "Firing: " << SDL_VIDEO_RESIZE << ".\n";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user