From 1075b719765d713a0426fcf042d048765d7dda35 Mon Sep 17 00:00:00 2001 From: Thomas Goyne Date: Tue, 7 Feb 2012 20:42:44 +0000 Subject: [PATCH] Prompt to update uses of the style when "Default" is renamed As far as I can tell, Default was only excluded to avoid prompting when creating a new style, but whether or not a style is new is now an explicit parameter to the editor so it's unneeded. Originally committed to SVN as r6453. --- aegisub/src/dialog_style_editor.cpp | 2 +- aegisub/src/dialog_style_manager.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/aegisub/src/dialog_style_editor.cpp b/aegisub/src/dialog_style_editor.cpp index ca566ff6d..de70749ae 100644 --- a/aegisub/src/dialog_style_editor.cpp +++ b/aegisub/src/dialog_style_editor.cpp @@ -374,7 +374,7 @@ void DialogStyleEditor::Apply(bool apply, bool close) { // Style name change bool did_rename = false; if (work->name != newStyleName) { - if (!store && !is_new && work->name != "Default") { + if (!store && !is_new) { // See if user wants to update style name through script int answer = wxMessageBox(_("Do you want to change all instances of this style in the script to this new name?"), _("Update script?"), wxYES_NO | wxCANCEL); diff --git a/aegisub/src/dialog_style_manager.cpp b/aegisub/src/dialog_style_manager.cpp index 63dbd91ef..4226d16d8 100644 --- a/aegisub/src/dialog_style_manager.cpp +++ b/aegisub/src/dialog_style_manager.cpp @@ -105,7 +105,7 @@ static wxSizer *make_edit_buttons(wxWindow *parent, wxString move_label, wxButto } DialogStyleManager::DialogStyleManager(agi::Context *context) -: wxDialog (context->parent,-1,_("Styles Manager"),wxDefaultPosition,wxDefaultSize,wxDEFAULT_DIALOG_STYLE,"DialogStylesManager") +: wxDialog(context->parent, -1, _("Styles Manager")) , c(context) { using std::tr1::bind;