From: Julian Smart Date: Tue, 11 Jun 2013 14:01:47 +0000 (+0000) Subject: Untranslated strings now won't be overwritten by regenerating the dialog. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/1c47b9489d9c7012dbf1e23620b0379a6b4ae31f?ds=inline Untranslated strings now won't be overwritten by regenerating the dialog. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74160 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/richtext/richtextdialogs.pjd b/src/richtext/richtextdialogs.pjd index 858e619281..b3c60d1a00 100644 --- a/src/richtext/richtextdialogs.pjd +++ b/src/richtext/richtextdialogs.pjd @@ -2502,14 +2502,6 @@ "wbBoxSizerProxy" "Vertical" "" - "Centre" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 0 0 0 @@ -3908,7 +3900,7 @@ 0 "10/11/2006" "wbComboBoxProxy" - "wxEVT_COMMAND_COMBOBOX_SELECTED|OnRichtextOutlinelevelSelected" + "wxEVT_COMMAND_COMBOBOX_SELECTED|OnRichtextOutlinelevelSelected|||wxRichTextIndentsSpacingPage" "ID_RICHTEXTINDENTSSPACINGPAGE_OUTLINELEVEL" 10105 "" @@ -3919,8 +3911,8 @@ "" "" "m_outlineLevelCtrl" - "(none)|1|2|3|4|5|6|7|8|9|10" - "(none)" + "" + "" "The outline level." "" "" @@ -8100,6 +8092,14 @@ "wbBoxSizerProxy" "Vertical" "" + "Centre" + "Centre" + 0 + 5 + 1 + 1 + 1 + 1 0 0 0 @@ -9341,6 +9341,14 @@ "wbBoxSizerProxy" "Vertical" "" + "Centre" + "Centre" + 0 + 5 + 1 + 1 + 1 + 1 0 0 0 diff --git a/src/richtext/richtextindentspage.cpp b/src/richtext/richtextindentspage.cpp index 15019ae7c0..96ef78f546 100644 --- a/src/richtext/richtextindentspage.cpp +++ b/src/richtext/richtextindentspage.cpp @@ -27,29 +27,17 @@ BEGIN_EVENT_TABLE( wxRichTextIndentsSpacingPage, wxRichTextDialogPage ) ////@begin wxRichTextIndentsSpacingPage event table entries EVT_RADIOBUTTON( ID_RICHTEXTINDENTSSPACINGPAGE_ALIGNMENT_LEFT, wxRichTextIndentsSpacingPage::OnAlignmentLeftSelected ) - EVT_RADIOBUTTON( ID_RICHTEXTINDENTSSPACINGPAGE_ALIGNMENT_RIGHT, wxRichTextIndentsSpacingPage::OnAlignmentRightSelected ) - EVT_RADIOBUTTON( ID_RICHTEXTINDENTSSPACINGPAGE_ALIGNMENT_JUSTIFIED, wxRichTextIndentsSpacingPage::OnAlignmentJustifiedSelected ) - EVT_RADIOBUTTON( ID_RICHTEXTINDENTSSPACINGPAGE_ALIGNMENT_CENTRED, wxRichTextIndentsSpacingPage::OnAlignmentCentredSelected ) - EVT_RADIOBUTTON( ID_RICHTEXTINDENTSSPACINGPAGE_ALIGNMENT_INDETERMINATE, wxRichTextIndentsSpacingPage::OnAlignmentIndeterminateSelected ) - EVT_TEXT( ID_RICHTEXTINDENTSSPACINGPAGE_INDENT_LEFT, wxRichTextIndentsSpacingPage::OnIndentLeftUpdated ) - EVT_TEXT( ID_RICHTEXTINDENTSSPACINGPAGE_INDENT_LEFT_FIRST, wxRichTextIndentsSpacingPage::OnIndentLeftFirstUpdated ) - EVT_TEXT( ID_RICHTEXTINDENTSSPACINGPAGE_INDENT_RIGHT, wxRichTextIndentsSpacingPage::OnIndentRightUpdated ) - EVT_COMBOBOX( ID_RICHTEXTINDENTSSPACINGPAGE_OUTLINELEVEL, wxRichTextIndentsSpacingPage::OnRichtextOutlinelevelSelected ) - EVT_TEXT( ID_RICHTEXTINDENTSSPACINGPAGE_SPACING_BEFORE, wxRichTextIndentsSpacingPage::OnSpacingBeforeUpdated ) - EVT_TEXT( ID_RICHTEXTINDENTSSPACINGPAGE_SPACING_AFTER, wxRichTextIndentsSpacingPage::OnSpacingAfterUpdated ) - EVT_COMBOBOX( ID_RICHTEXTINDENTSSPACINGPAGE_SPACING_LINE, wxRichTextIndentsSpacingPage::OnSpacingLineSelected ) - ////@end wxRichTextIndentsSpacingPage event table entries END_EVENT_TABLE() @@ -236,19 +224,7 @@ void wxRichTextIndentsSpacingPage::CreateControls() itemFlexGridSizer22->Add(itemStaticText29, 0, wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL|wxALL, 5); wxArrayString m_outlineLevelCtrlStrings; - m_outlineLevelCtrlStrings.Add(_("(none)")); - m_outlineLevelCtrlStrings.Add("1"); - m_outlineLevelCtrlStrings.Add("2"); - m_outlineLevelCtrlStrings.Add("3"); - m_outlineLevelCtrlStrings.Add("4"); - m_outlineLevelCtrlStrings.Add("5"); - m_outlineLevelCtrlStrings.Add("6"); - m_outlineLevelCtrlStrings.Add("7"); - m_outlineLevelCtrlStrings.Add("8"); - m_outlineLevelCtrlStrings.Add("9"); - m_outlineLevelCtrlStrings.Add("10"); - m_outlineLevelCtrl = new wxComboBox( itemRichTextDialogPage1, ID_RICHTEXTINDENTSSPACINGPAGE_OUTLINELEVEL, _("(none)"), wxDefaultPosition, wxSize(85, -1), m_outlineLevelCtrlStrings, wxCB_READONLY ); - m_outlineLevelCtrl->SetStringSelection(_("(none)")); + m_outlineLevelCtrl = new wxComboBox( itemRichTextDialogPage1, ID_RICHTEXTINDENTSSPACINGPAGE_OUTLINELEVEL, wxEmptyString, wxDefaultPosition, wxSize(85, -1), m_outlineLevelCtrlStrings, wxCB_READONLY ); m_outlineLevelCtrl->SetHelpText(_("The outline level.")); if (wxRichTextIndentsSpacingPage::ShowToolTips()) m_outlineLevelCtrl->SetToolTip(_("The outline level.")); @@ -331,6 +307,24 @@ void wxRichTextIndentsSpacingPage::CreateControls() itemBoxSizer3->Add(m_previewCtrl, 1, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); ////@end wxRichTextIndentsSpacingPage content construction + + wxArrayString outlineLevelCtrlStrings; + outlineLevelCtrlStrings.Add(_("(none)")); + outlineLevelCtrlStrings.Add("1"); + outlineLevelCtrlStrings.Add("2"); + outlineLevelCtrlStrings.Add("3"); + outlineLevelCtrlStrings.Add("4"); + outlineLevelCtrlStrings.Add("5"); + outlineLevelCtrlStrings.Add("6"); + outlineLevelCtrlStrings.Add("7"); + outlineLevelCtrlStrings.Add("8"); + outlineLevelCtrlStrings.Add("9"); + outlineLevelCtrlStrings.Add("10"); + + m_outlineLevelCtrl->Freeze(); + m_outlineLevelCtrl->Append(outlineLevelCtrlStrings); + m_outlineLevelCtrl->Thaw(); + m_outlineLevelCtrl->SetStringSelection(_("(none)")); } wxRichTextAttr* wxRichTextIndentsSpacingPage::GetAttributes()