# HG changeset patch # User ib # Date 1359162456 0 # Node ID 25852c7400933595d3a750071dbce10001f007b9 # Parent 8e5a3da0a8585422c47177a67609b7a41e3542d6 Remove code almost identical to uiMenuDone() plus uiMenuInit(). Nothing but uiMenuDone() destroys the menu and nothing but uiMenuInit() builds it. This is analogous to rebuilding the playbar now. diff -r 8e5a3da0a858 -r 25852c740093 gui/ui/actions.c --- a/gui/ui/actions.c Sat Jan 26 00:53:25 2013 +0000 +++ b/gui/ui/actions.c Sat Jan 26 01:07:36 2013 +0000 @@ -635,21 +635,10 @@ /* reload menu window */ - if (was_menu && guiApp.menuIsPresent) { - free(menuDrawBuffer); - menuDrawBuffer = calloc(1, guiApp.menu.Bitmap.ImageSize); + if (was_menu) + uiMenuDone(); - if (!menuDrawBuffer) { - gmp_msg(MSGT_GPLAYER, MSGL_FATAL, MSGTR_NEMDB); - mplayer(MPLAYER_EXIT_GUI, EXIT_ERROR, 0); - } - - wsWindowResize(&guiApp.menuWindow, guiApp.menu.width, guiApp.menu.height); - wsImageResize(&guiApp.menuWindow, guiApp.menu.width, guiApp.menu.height); - wsWindowShape(&guiApp.menuWindow, guiApp.menu.Mask.Image); - wsWindowVisibility(&guiApp.menuWindow, wsHideWindow); - } else - uiMenuInit(); + uiMenuInit(); /* */