diff --git a/src/game/client/components/menus.cpp b/src/game/client/components/menus.cpp index 7da4f5d48..60820d5be 100644 --- a/src/game/client/components/menus.cpp +++ b/src/game/client/components/menus.cpp @@ -543,7 +543,7 @@ int MENUS::render_menubar(RECT r) static int demos_button=0; if (ui_do_button(&demos_button, "Demos", active_page==PAGE_DEMOS, &button, ui_draw_menu_tab_button, 0)) { - //client_serverbrowse_refresh(BROWSETYPE_FAVORITES); + demolist_populate(); new_page = PAGE_DEMOS; } } diff --git a/src/game/client/components/menus_demo.cpp b/src/game/client/components/menus_demo.cpp index 1d94e7362..a8ed01772 100644 --- a/src/game/client/components/menus_demo.cpp +++ b/src/game/client/components/menus_demo.cpp @@ -378,13 +378,23 @@ void MENUS::render_demolist(RECT main_view) } selected_item = ui_do_listbox_end(); - RECT button; - ui_vsplit_r(&buttonbar, 120.0f, &buttonbar, &button); + RECT refresh_rect, play_rect; + ui_vsplit_r(&buttonbar, 250.0f, &buttonbar, &refresh_rect); + ui_vsplit_r(&refresh_rect, 130.0f, &refresh_rect, &play_rect); + ui_vsplit_r(&play_rect, 120.0f, 0x0, &play_rect); + + static int refresh_button = 0; + if(ui_do_button(&refresh_button, "Refresh", 0, &refresh_rect, ui_draw_menu_button, 0)) + { + demolist_populate(); + } + static int play_button = 0; - if(ui_do_button(&play_button, "Play", 0, &button, ui_draw_menu_button, 0)) + if(ui_do_button(&play_button, "Play", 0, &play_rect, ui_draw_menu_button, 0)) { if(selected_item >= 0 && selected_item < num_demos) client_demoplayer_play(demos[selected_item].filename); } + }