Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GUI2: convert remaining uses of dialog_callback to std::bind
dialog_callback was designed to be passed where a void(widget&) function was expected. It took the widget parameter, then found its dialog and window, and called the given callback on that dialog object with the window as a parameter. I had left a few remaining usecases for convenience, but it's not needed anymore. * Faction Select: window parameter can be directly bound with std::ref * Unit Create: window parameter not even needed, was only there to satisfy dialog_callback's signature. * MP Create Game: window parameter needed, but I changed it to an in-function variable using modal_dialog::get_window. There's no window object to directly bind in the constructor, and using the actual callback widget's own get_window method just seems redundant.
- Loading branch information
Showing
5 changed files
with
11 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters