From 718903fe6402bb374a801e43e856b02204401204 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Fri, 18 Feb 2005 17:49:03 +0000 Subject: [PATCH] wxStdButtonSizer Finalise --> Realize git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32146 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- docs/latex/wx/stdbtnsz.tex | 6 +++--- include/wx/sizer.h | 2 +- samples/calendar/calendar.cpp | 2 +- src/common/dlgcmn.cpp | 2 +- src/common/sizer.cpp | 2 +- wxPython/demo/Validator.py | 2 +- wxPython/src/_sizers.i | 4 ++-- wxPython/wx/lib/dialogs.py | 2 +- 8 files changed, 11 insertions(+), 11 deletions(-) diff --git a/docs/latex/wx/stdbtnsz.tex b/docs/latex/wx/stdbtnsz.tex index 256d08f6a8..065acd3485 100644 --- a/docs/latex/wx/stdbtnsz.tex +++ b/docs/latex/wx/stdbtnsz.tex @@ -9,7 +9,7 @@ When there aren't interface guidelines defined for a particular platform or tool to the Windows implementation. To use this class, first add buttons to the sizer by calling AddButton (or SetAffirmativeButton, SetNegativeButton, -or SetCancelButton) and then call Finalise in order to create the actual button layout used. Other than these special +or SetCancelButton) and then call Realize in order to create the actual button layout used. Other than these special operations, this sizer works like any other sizer. If you add a button with wxID\_SAVE, on Mac OS X the button will be renamed to "Save" and @@ -52,9 +52,9 @@ Adds a button to the wxStdDialogButtonSizer. The button must have one of the fol \item wxID\_CONTEXT\_HELP \end{itemize} -\membersection{wxStdDialogButtonSizer::Finalise}\label{wxstddialogbuttonsizerfinalise} +\membersection{wxStdDialogButtonSizer::Realize}\label{wxstddialogbuttonsizerrealize} -\func{void}{Finalise}{\void} +\func{void}{Realize}{\void} Rearranges the buttons and applies proper spacing between buttons to make them match the platform or toolkit's interface guidelines. diff --git a/include/wx/sizer.h b/include/wx/sizer.h index c38c47a0ef..c245371191 100644 --- a/include/wx/sizer.h +++ b/include/wx/sizer.h @@ -669,7 +669,7 @@ public: // is set to _("Save") and m_buttonNegative is set to _("Don't Save") // I wouldn't add any other hacks like that into here, // but this one I can see being useful. - void Finalise(); + void Realize(); wxButton *GetAffirmativeButton() const { return m_buttonAffirmative; } wxButton *GetApplyButton() const { return m_buttonApply; } diff --git a/samples/calendar/calendar.cpp b/samples/calendar/calendar.cpp index 9cc91601f7..9874f0f547 100644 --- a/samples/calendar/calendar.cpp +++ b/samples/calendar/calendar.cpp @@ -595,7 +595,7 @@ MyDialog::MyDialog(wxWindow *parent, const wxDateTime& dt, int dtpStyle) wxStdDialogButtonSizer *sizerBtns = new wxStdDialogButtonSizer; sizerBtns->AddButton(new wxButton(this, wxID_OK)); sizerBtns->AddButton(new wxButton(this, wxID_CANCEL)); - sizerBtns->Finalise(); + sizerBtns->Realize(); wxSizer *sizerText = new wxBoxSizer(wxHORIZONTAL); sizerText->Add(new wxStaticText(this, wxID_ANY, _T("Date in ISO format: ")), diff --git a/src/common/dlgcmn.cpp b/src/common/dlgcmn.cpp index f810b795a4..ca535d37d2 100644 --- a/src/common/dlgcmn.cpp +++ b/src/common/dlgcmn.cpp @@ -205,7 +205,7 @@ wxStdDialogButtonSizer *wxDialogBase::CreateStdDialogButtonSizer( long flags ) sizer->AddButton(help); } - sizer->Finalise(); + sizer->Realize(); if (flags & wxNO_DEFAULT) { diff --git a/src/common/sizer.cpp b/src/common/sizer.cpp index 60f03929c5..f787a74ffc 100644 --- a/src/common/sizer.cpp +++ b/src/common/sizer.cpp @@ -1728,7 +1728,7 @@ void wxStdDialogButtonSizer::SetCancelButton( wxButton *button ) m_buttonCancel = button; } -void wxStdDialogButtonSizer::Finalise() +void wxStdDialogButtonSizer::Realize() { #ifdef __WXMAC__ Add(0, 0, 0, wxLEFT, 6); diff --git a/wxPython/demo/Validator.py b/wxPython/demo/Validator.py index 688712c015..31dd044967 100644 --- a/wxPython/demo/Validator.py +++ b/wxPython/demo/Validator.py @@ -193,7 +193,7 @@ class TestValidateDialog(wx.Dialog): b.SetDefault() buttons.AddButton(b) buttons.AddButton(wx.Button(self, wx.ID_CANCEL, "Cancel")) - buttons.Finalise() + buttons.Realize() border = wx.BoxSizer(wx.VERTICAL) border.Add(fgs, 1, wx.GROW|wx.ALL, 25) diff --git a/wxPython/src/_sizers.i b/wxPython/src/_sizers.i index e34ed95a19..8fe5f1b071 100644 --- a/wxPython/src/_sizers.i +++ b/wxPython/src/_sizers.i @@ -1270,7 +1270,7 @@ DocStr(wxStdDialogButtonSizer, "A special sizer that knows how to order and position standard buttons in order to conform to the current platform's standards. You simply need to add each `wx.Button` to the sizer, and be sure to create the -buttons using the standard ID's. Then call `Finalize` and the sizer +buttons using the standard ID's. Then call `Realize` and the sizer will take care of the rest. ", ""); @@ -1287,7 +1287,7 @@ public: method in the base class.", ""); DocDeclStr( - void , Finalise(), + void , Realize(), "This funciton needs to be called after all the buttons have been added to the sizer. It will reorder them and position them in a platform specifc manner.", ""); diff --git a/wxPython/wx/lib/dialogs.py b/wxPython/wx/lib/dialogs.py index fa5c461435..395d36dde8 100644 --- a/wxPython/wx/lib/dialogs.py +++ b/wxPython/wx/lib/dialogs.py @@ -77,7 +77,7 @@ class MultipleChoiceDialog(wx.Dialog): btnsizer = wx.StdDialogButtonSizer() btnsizer.AddButton(ok) btnsizer.AddButton(cancel) - btnsizer.Finalise() + btnsizer.Realize() dlgsizer.Add(btnsizer, 0, wx.ALL | wx.ALIGN_RIGHT, 4) -- 2.47.2