Author: mir3x Date: Thu Nov 17 10:23:06 2016 New Revision: 34542 URL: http://svn.gna.org/viewcvs/freeciv?rev=34542&view=rev Log: Qt client - ported popup_soundset_suggestion_dialog()
See patch #7993 Modified: branches/S2_6/client/gui-qt/dialogs.cpp Modified: branches/S2_6/client/gui-qt/dialogs.cpp URL: http://svn.gna.org/viewcvs/freeciv/branches/S2_6/client/gui-qt/dialogs.cpp?rev=34542&r1=34541&r2=34542&view=diff ============================================================================== --- branches/S2_6/client/gui-qt/dialogs.cpp (original) +++ branches/S2_6/client/gui-qt/dialogs.cpp Thu Nov 17 10:23:06 2016 @@ -39,6 +39,7 @@ #include "research.h" // client +#include "audio.h" #include "control.h" #include "helpdata.h" #include "packhand.h" @@ -2412,7 +2413,23 @@ *****************************************************************/ void popup_soundset_suggestion_dialog(void) { - qDebug() << Q_FUNC_INFO << "PORTME"; + hud_message_box ask(gui()->central_wdg); + QString text; + QString title; + QPushButton *ok_button; + + title = QString(_("Modpack suggests using %1 soundset.")) + .arg(game.control.preferred_soundset); + text = QString("It might not work with other tilesets.\n" + "You are currently using soundset %1.") + .arg(sound_set_name); + ask.addButton(_("Keep current soundset"), QMessageBox::ActionRole); + ok_button = ask.addButton(_("Load soundset"), QMessageBox::ActionRole); + ask.set_text_title(text, title); + ask.exec(); + if (ask.clickedButton() == ok_button) { + audio_restart(game.control.preferred_soundset, music_set_name); + } } /**************************************************************** _______________________________________________ Freeciv-commits mailing list Freeciv-commits@gna.org https://mail.gna.org/listinfo/freeciv-commits