diff --git a/CHANGES.rst b/CHANGES.rst index f366e069..ca1ac7ac 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -72,6 +72,8 @@ Changes in this release include the following: * Ensure that the page exists in book controls GetPage and RemovePage methods. At least one of the wx ports do not do this. (#830) +* Added missing wx.NumberEntryDialog + diff --git a/docs/classic_vs_phoenix.rst b/docs/classic_vs_phoenix.rst index fa42dcce..51d2f2fa 100644 --- a/docs/classic_vs_phoenix.rst +++ b/docs/classic_vs_phoenix.rst @@ -336,7 +336,6 @@ NotebookEvent :class:`wx.BookCtrl NotebookPage ``MISSING`` NotificationMessage :class:`wx.adv.NotificationMessage` NullFileTypeInfo ``MISSING`` -NumberEntryDialog ``MISSING`` Panel_GetClassDefaultAttributes :meth:`wx.Panel.GetClassDefaultAttributes ` PCXHandler ``MISSING`` PlatformInformation_GetOperatingSystemDirectory :meth:`wx.PlatformInfo.GetOperatingSystemDirectory` diff --git a/docs/sphinx/itemToModuleMap.json b/docs/sphinx/itemToModuleMap.json index 0241f0e0..891f90b5 100644 --- a/docs/sphinx/itemToModuleMap.json +++ b/docs/sphinx/itemToModuleMap.json @@ -2373,6 +2373,7 @@ "NullPalette":"wx.", "NullPen":"wx.", "NullRegion":"wx.", +"NumberEntryDialog":"wx.", "NumericPropertyValidator":"wx.propgrid.", "NumericType":"wx.propgrid.NumericPropertyValidator.", "ODCB_DCLICK_CYCLES":"wx.adv.", diff --git a/etg/numdlg.py b/etg/numdlg.py index 97538f2c..e2ccdddb 100644 --- a/etg/numdlg.py +++ b/etg/numdlg.py @@ -17,8 +17,7 @@ DOCSTRING = "" # The classes and/or the basename of the Doxygen XML files to be processed by # this script. -ITEMS = [ 'numdlg_8h.xml', - +ITEMS = [ 'wxNumberEntryDialog', ] #--------------------------------------------------------------------------- @@ -34,6 +33,9 @@ def run(): module.addHeaderCode('#include ') + c = module.find('wxNumberEntryDialog') + tools.fixTopLevelWindowClass(c) + c = module.find('wxGetNumberFromUser') c.mustHaveApp() diff --git a/ext/wxWidgets b/ext/wxWidgets index 721d62ad..d19abf60 160000 --- a/ext/wxWidgets +++ b/ext/wxWidgets @@ -1 +1 @@ -Subproject commit 721d62adde3f8ba8704a9cf56efeb050f652dfbf +Subproject commit d19abf606d5479ce28b8f7fcc67ee3742c69de25 diff --git a/unittests/test_numdlg.py b/unittests/test_numdlg.py index 6e888a60..cd944a54 100644 --- a/unittests/test_numdlg.py +++ b/unittests/test_numdlg.py @@ -6,9 +6,16 @@ import wx class numdlg_Tests(wtc.WidgetTestCase): - # TODO: Remove this test and add real ones. def test_numdlg1(self): - self.fail("Unit tests for numdlg not implemented yet.") + dlg = wx.NumberEntryDialog(None, "Message", "Prompt", "Caption", 50, 0, 100) + wx.CallLater(250, dlg.EndModal, wx.ID_OK) + dlg.ShowModal() + self.assertEqual(dlg.GetValue(), 50) + dlg.Destroy() + + def test_numdlg2(self): + # Ideally we would call this but don't know how to dismiss the dialog + wx.GetNumberFromUser #---------------------------------------------------------------------------