From e77d093dbe5a09a91600d9ff95a9b0853f2b605d Mon Sep 17 00:00:00 2001 From: =?utf8?q?W=C5=82odzimierz=20Skiba?= Date: Thu, 3 Jun 2004 10:32:41 +0000 Subject: [PATCH] Cleaning. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27598 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- samples/sashtest/sashtest.cpp | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/samples/sashtest/sashtest.cpp b/samples/sashtest/sashtest.cpp index 2ae188a8aa..560a5ebc90 100644 --- a/samples/sashtest/sashtest.cpp +++ b/samples/sashtest/sashtest.cpp @@ -42,7 +42,7 @@ bool MyApp::OnInit(void) { // Create the main frame window - frame = new MyFrame(NULL, -1, _T("Sash Demo"), wxPoint(0, 0), wxSize(500, 400), + frame = new MyFrame(NULL, wxID_ANY, _T("Sash Demo"), wxPoint(0, 0), wxSize(500, 400), wxDEFAULT_FRAME_STYLE | wxNO_FULL_REPAINT_ON_RESIZE | wxHSCROLL | wxVSCROLL); @@ -72,11 +72,11 @@ bool MyApp::OnInit(void) frame->CreateStatusBar(); - frame->Show(TRUE); + frame->Show(true); SetTopWindow(frame); - return TRUE; + return true; } BEGIN_EVENT_TABLE(MyFrame, wxMDIParentFrame) @@ -106,7 +106,7 @@ MyFrame::MyFrame(wxWindow *parent, const wxWindowID id, const wxString& title, c win->SetOrientation(wxLAYOUT_HORIZONTAL); win->SetAlignment(wxLAYOUT_TOP); win->SetBackgroundColour(wxColour(255, 0, 0)); - win->SetSashVisible(wxSASH_BOTTOM, TRUE); + win->SetSashVisible(wxSASH_BOTTOM, true); m_topWindow = win; @@ -118,7 +118,7 @@ MyFrame::MyFrame(wxWindow *parent, const wxWindowID id, const wxString& title, c win->SetOrientation(wxLAYOUT_HORIZONTAL); win->SetAlignment(wxLAYOUT_BOTTOM); win->SetBackgroundColour(wxColour(0, 0, 255)); - win->SetSashVisible(wxSASH_TOP, TRUE); + win->SetSashVisible(wxSASH_TOP, true); m_bottomWindow = win; @@ -130,10 +130,10 @@ MyFrame::MyFrame(wxWindow *parent, const wxWindowID id, const wxString& title, c win->SetOrientation(wxLAYOUT_VERTICAL); win->SetAlignment(wxLAYOUT_LEFT); win->SetBackgroundColour(wxColour(0, 255, 0)); - win->SetSashVisible(wxSASH_RIGHT, TRUE); + win->SetSashVisible(wxSASH_RIGHT, true); win->SetExtraBorderSize(10); - wxTextCtrl* textWindow = new wxTextCtrl(win, -1, _T(""), wxDefaultPosition, wxDefaultSize, + wxTextCtrl* textWindow = new wxTextCtrl(win, wxID_ANY, _T(""), wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxSUNKEN_BORDER); // wxTE_MULTILINE|wxNO_BORDER); textWindow->SetValue(_T("A help window")); @@ -148,14 +148,14 @@ MyFrame::MyFrame(wxWindow *parent, const wxWindowID id, const wxString& title, c win->SetOrientation(wxLAYOUT_VERTICAL); win->SetAlignment(wxLAYOUT_LEFT); win->SetBackgroundColour(wxColour(0, 255, 255)); - win->SetSashVisible(wxSASH_RIGHT, TRUE); + win->SetSashVisible(wxSASH_RIGHT, true); m_leftWindow2 = win; } void MyFrame::OnQuit(wxCommandEvent& WXUNUSED(event)) { - Close(TRUE); + Close(true); } void MyFrame::OnAbout(wxCommandEvent& WXUNUSED(event)) @@ -167,11 +167,11 @@ void MyFrame::OnToggleWindow(wxCommandEvent& WXUNUSED(event)) { if (m_leftWindow1->IsShown()) { - m_leftWindow1->Show(FALSE); + m_leftWindow1->Show(false); } else { - m_leftWindow1->Show(TRUE); + m_leftWindow1->Show(true); } wxLayoutAlgorithm layout; layout.LayoutMDIFrame(this); @@ -264,7 +264,7 @@ void MyFrame::OnNewWindow(wxCommandEvent& WXUNUSED(event)) // Give it scrollbars canvas->SetScrollbars(20, 20, 50, 50); - subframe->Show(TRUE); + subframe->Show(true); } BEGIN_EVENT_TABLE(MyCanvas, wxScrolledWindow) @@ -273,7 +273,7 @@ END_EVENT_TABLE() // Define a constructor for my canvas MyCanvas::MyCanvas(wxWindow *parent, const wxPoint& pos, const wxSize& size) - : wxScrolledWindow(parent, -1, pos, size, + : wxScrolledWindow(parent, wxID_ANY, pos, size, wxSUNKEN_BORDER | wxNO_FULL_REPAINT_ON_RESIZE) { SetBackgroundColour(* wxWHITE); @@ -341,7 +341,7 @@ END_EVENT_TABLE() MyChild::MyChild(wxMDIParentFrame *parent, const wxString& title, const wxPoint& pos, const wxSize& size, const long style): - wxMDIChildFrame(parent, -1, title, pos, size, style) + wxMDIChildFrame(parent, wxID_ANY, title, pos, size, style) { canvas = NULL; my_children.Append(this); @@ -354,7 +354,7 @@ MyChild::~MyChild(void) void MyChild::OnQuit(wxCommandEvent& WXUNUSED(event)) { - Close(TRUE); + Close(true); } void MyChild::OnActivate(wxActivateEvent& event) -- 2.45.2