From 5d5278db8808aff71e592739d153b5273cd69c41 Mon Sep 17 00:00:00 2001 From: Rodrigo Braz Monteiro Date: Thu, 18 Oct 2007 15:42:07 +0000 Subject: [PATCH] Changed buttons for the resample dialog and made call tips be off by default. Originally committed to SVN as r1608. --- aegisub/dialog_resample.cpp | 19 +++++++------------ aegisub/dialog_resample.h | 1 - aegisub/options.cpp | 2 +- 3 files changed, 8 insertions(+), 14 deletions(-) diff --git a/aegisub/dialog_resample.cpp b/aegisub/dialog_resample.cpp index 5fe3f7739..cfa368ea9 100644 --- a/aegisub/dialog_resample.cpp +++ b/aegisub/dialog_resample.cpp @@ -46,6 +46,7 @@ #include "video_context.h" #include "utils.h" #include "subs_edit_box.h" +#include "help_button.h" /////////////// @@ -104,17 +105,11 @@ DialogResample::DialogResample(wxWindow *parent, SubtitlesGrid *_grid) ResBoxSizer->Add(Anamorphic,0,0,0); // Button sizer - wxSizer *ButtonSizer = new wxBoxSizer(wxHORIZONTAL); - ButtonSizer->AddStretchSpacer(1); -#ifndef __WXMAC__ - ButtonSizer->Add(new wxButton(this,BUTTON_RESAMPLE,_("Resample")),0,wxRIGHT,5); - ButtonSizer->Add(new wxButton(this,wxID_CANCEL),0,wxRIGHT,0); -#else - ButtonSizer->Add(new wxButton(this,wxID_CANCEL),0,wxRIGHT,5); - wxButton *resampleButton = new wxButton(this,BUTTON_RESAMPLE,_("Resample")); - ButtonSizer->Add(resampleButton,0,wxRight,0); - resampleButton->SetDefault(); -#endif + wxStdDialogButtonSizer *ButtonSizer = new wxStdDialogButtonSizer(); + ButtonSizer->AddButton(new wxButton(this,wxID_OK)); + ButtonSizer->AddButton(new wxButton(this,wxID_CANCEL)); + ButtonSizer->AddButton(new HelpButton(this,_T("dialog_resample"))); + ButtonSizer->Realize(); // Main sizer wxSizer *MainSizer = new wxBoxSizer(wxVERTICAL); @@ -131,7 +126,7 @@ DialogResample::DialogResample(wxWindow *parent, SubtitlesGrid *_grid) /////////////// // Event table BEGIN_EVENT_TABLE(DialogResample,wxDialog) - EVT_BUTTON(BUTTON_RESAMPLE,DialogResample::OnResample) + EVT_BUTTON(wxID_OK,DialogResample::OnResample) EVT_BUTTON(BUTTON_DEST_FROM_VIDEO,DialogResample::OnGetDestRes) EVT_CHECKBOX(CHECK_SYMMETRICAL,DialogResample::OnSymmetrical) EVT_TEXT(TEXT_MARGIN_T,DialogResample::OnMarginChange) diff --git a/aegisub/dialog_resample.h b/aegisub/dialog_resample.h index 2b656b34a..23c2f1fe4 100644 --- a/aegisub/dialog_resample.h +++ b/aegisub/dialog_resample.h @@ -91,7 +91,6 @@ public: // IDs enum { BUTTON_DEST_FROM_VIDEO = 1520, - BUTTON_RESAMPLE, CHECK_ANAMORPHIC, CHECK_SYMMETRICAL, TEXT_MARGIN_T, diff --git a/aegisub/options.cpp b/aegisub/options.cpp index 4d3f942c1..8dcd51dd1 100644 --- a/aegisub/options.cpp +++ b/aegisub/options.cpp @@ -116,7 +116,7 @@ void OptionsManager::LoadDefaults(bool onlyDefaults) { SetBool(_T("Insert mode on time boxes"),false); #endif SetModificationType(MOD_EDIT_BOX); - SetBool(_T("Call tips enabled"),true); + SetBool(_T("Call tips enabled"),false); SetBool(_T("Syntax highlight enabled"),true); // Edit box cosmetic