Ignore:
Timestamp:
2010-05-28 07:39:52 (2 years ago)
Author:
kpoole
Message:

Episode 5

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Classes/gui/dialogs/wml_message.cpp

    r4 r26  
    2222#include "gui/widgets/text_box.hpp" 
    2323#include "gui/widgets/window.hpp" 
     24 
     25#include "game_display.hpp" 
     26#include "construct_dialog.hpp" 
    2427 
    2528namespace gui2 { 
     
    255258 
    256259    if(!option_list.empty()) { 
    257         dlg->set_option_list(option_list, chosen_option); 
     260        //dlg->set_option_list(option_list, chosen_option); 
     261        // KP: totally redo the option list stuff.... 
     262        std::string optDlgTitle = "Choose an option..."; 
     263        gui::dialog optDlg = gui::dialog(*game_display::get_singleton(), //gui, 
     264                                           optDlgTitle, 
     265                                           message, 
     266                                           gui::OK_ONLY); 
     267        std::vector<shared_string> opts; 
     268        for (std::vector<std::string>::const_iterator it=option_list.begin(); it != option_list.end(); it++) 
     269        { 
     270            // +d+ 
     271            opts.push_back("&misc/spacer_45.png=]" + *it); 
     272//          opts.push_back(*it); 
     273        } 
     274        optDlg.set_menu(opts); 
     275        int result = optDlg.show(); 
     276        *chosen_option = result; 
     277        return twindow::OK; 
    258278    } 
    259279 
Note: See TracChangeset for help on using the changeset viewer.