From cc87fbed40e46f70ce89c9acf4368bf556840ac0 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 10 Aug 2006 15:46:49 +0000 Subject: [PATCH] removed wxHtmlWindow::m_Style which duplicated wxWindow::m_windowStyle and prevented changeing wxHW_XXX window style after Create() from working git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40553 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/html/htmlwin.h | 2 -- src/html/htmlwin.cpp | 10 ++++------ 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/include/wx/html/htmlwin.h b/include/wx/html/htmlwin.h index c79131c587..1930ade24f 100644 --- a/include/wx/html/htmlwin.h +++ b/include/wx/html/htmlwin.h @@ -488,8 +488,6 @@ protected: // defaults to 10 pixels. int m_Borders; - int m_Style; - // current text selection or NULL wxHtmlSelection *m_selection; diff --git a/src/html/htmlwin.cpp b/src/html/htmlwin.cpp index 19bc93a9da..431b30b32c 100644 --- a/src/html/htmlwin.cpp +++ b/src/html/htmlwin.cpp @@ -277,7 +277,6 @@ void wxHtmlWindow::Init() m_HistoryOn = true; m_History = new wxHtmlHistoryArray; m_Processors = NULL; - m_Style = 0; SetBorders(10); m_selection = NULL; m_makingSelection = false; @@ -299,7 +298,6 @@ bool wxHtmlWindow::Create(wxWindow *parent, wxWindowID id, name)) return false; - m_Style = style; SetPage(wxT("")); return true; } @@ -638,14 +636,14 @@ void wxHtmlWindow::CreateLayout() if (!m_Cell) return; - if (m_Style & wxHW_SCROLLBAR_NEVER) + if ( HasFlag(wxHW_SCROLLBAR_NEVER) ) { SetScrollbars(1, 1, 0, 0); // always off GetClientSize(&ClientWidth, &ClientHeight); m_Cell->Layout(ClientWidth); } - - else { + else // !wxHW_SCROLLBAR_NEVER + { GetClientSize(&ClientWidth, &ClientHeight); m_Cell->Layout(ClientWidth); if (ClientHeight < m_Cell->GetHeight() + GetCharHeight()) @@ -842,7 +840,7 @@ void wxHtmlWindow::AddFilter(wxHtmlFilter *filter) bool wxHtmlWindow::IsSelectionEnabled() const { #if wxUSE_CLIPBOARD - return !(m_Style & wxHW_NO_SELECTION); + return !HasFlag(wxHW_NO_SELECTION); #else return false; #endif -- 2.45.2