On 2014-12-11 at 11:49, Gerd Hoffmann wrote:
Split do_sdl_resize function (which does alot more than just resizing)
into three: sdl2_window_{create,destroy,resize}.

Fix SDL_Renderer handling: must be guest display size not host window
size, and SDL2 will magically handle all scaling for us.

Make fullscreen actually enter fullscreen mode and simplify the code.
There is no need to store the original window size, the window manager
will do that for us.

Signed-off-by: Gerd Hoffmann <kra...@redhat.com>
---
  ui/sdl2.c | 172 +++++++++++++++++++++++++++++---------------------------------
  1 file changed, 79 insertions(+), 93 deletions(-)

diff --git a/ui/sdl2.c b/ui/sdl2.c
index 47a757a..70f79a5 100644
--- a/ui/sdl2.c
+++ b/ui/sdl2.c

[snip]

  static void sdl_switch(DisplayChangeListener *dcl,
                         DisplaySurface *new_surface)
  {
      struct sdl2_console *scon = container_of(dcl, struct sdl2_console, dcl);
-    int format = 0;
-    int idx = scon->idx;
      DisplaySurface *old_surface = scon->surface;
+    int format = 0;

Moving "format" seems unnecessary, but of course it doesn't matter.

Reviewed-by: Max Reitz <mre...@redhat.com>

Reply via email to