From de491dd67fa3ded88ce713b346d561c2da3394dd Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 27 Feb 2016 01:56:23 +0100 Subject: [PATCH] Show wxTestableFrame from its ctor No real changes, just always show the frame as we need it to be shown for the tests to run anyhow. Also update the nonsensical comment about creating a hidden window just before showing it. --- tests/test.cpp | 5 ++--- tests/testableframe.cpp | 2 ++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/test.cpp b/tests/test.cpp index 55f741af62..85060d3cd4 100644 --- a/tests/test.cpp +++ b/tests/test.cpp @@ -559,9 +559,8 @@ bool TestApp::OnInit() cout << std::endl; #if wxUSE_GUI - // create a hidden parent window to be used as parent for the GUI controls - wxTestableFrame* frame = new wxTestableFrame(); - frame->Show(); + // create a parent window to be used as parent for the GUI controls + new wxTestableFrame(); Connect(wxEVT_IDLE, wxIdleEventHandler(TestApp::OnIdle)); #endif // wxUSE_GUI diff --git a/tests/testableframe.cpp b/tests/testableframe.cpp index 1b63defb88..dc535a1f43 100644 --- a/tests/testableframe.cpp +++ b/tests/testableframe.cpp @@ -20,6 +20,8 @@ wxTestableFrame::wxTestableFrame() : wxFrame(NULL, wxID_ANY, "Test Frame") { // Use fixed position to facilitate debugging. Move(200, 200); + + Show(); } void wxTestableFrame::OnEvent(wxEvent& evt)