#pragma hdrstop
#endif
-#include <wx/string.h>
-#include <wx/log.h>
-#include <wx/settings.h>
-#include <wx/generic/imaglist.h>
-#include <wx/notebook.h>
-#include <wx/dcclient.h>
+#include "wx/string.h"
+#include "wx/log.h"
+#include "wx/settings.h"
+#include "wx/generic/imaglist.h"
+#include "wx/notebook.h"
+#include "wx/dcclient.h"
// ----------------------------------------------------------------------------
// macros
// event table
// ----------------------------------------------------------------------------
-#if !USE_SHARED_LIBRARIES
+DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED)
+DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING)
+
BEGIN_EVENT_TABLE(wxNotebook, wxControl)
EVT_NOTEBOOK_PAGE_CHANGED(-1, wxNotebook::OnSelChange)
EVT_SIZE(wxNotebook::OnSize)
IMPLEMENT_DYNAMIC_CLASS(wxNotebook, wxControl)
IMPLEMENT_DYNAMIC_CLASS(wxNotebookEvent, wxCommandEvent)
-#endif
// ============================================================================
// implementation
}
void wxNotebook::SetImageList(wxImageList* imageList)
-{
+{
m_pImageList = imageList;
// TODO
}
rect.y = tabHeight + 4;
rect.width = cw - 8;
rect.height = ch - 4 - rect.y ;
-
+
m_tabView->SetViewRect(rect);
m_tabView->LayoutTabs();
rect.y = tabHeight + 4;
rect.width = cw - 8;
rect.height = ch - 4 - rect.y ;
-
+
m_tabView->SetViewRect(rect);
m_tabView->LayoutTabs();
return TRUE;
}
-void wxNotebook::Command(wxCommandEvent& event)
+void wxNotebook::Command(wxCommandEvent& WXUNUSED(event))
{
wxFAIL_MSG("wxNotebook::Command not implemented");
}
wxRect clientRect = GetAvailableClientSize();
pPage->SetSize(clientRect.x, clientRect.y, clientRect.width, clientRect.height);
+ Refresh();
+
pPage->Show(TRUE);
pPage->Raise();
pPage->SetFocus();
- Refresh();
-
m_nSelection = nSel;
}
/*
* wxNotebookTabView
*/
-
+
IMPLEMENT_CLASS(wxNotebookTabView, wxTabView)
wxNotebookTabView::wxNotebookTabView(wxNotebook *notebook, long style): wxTabView(style)
if (!m_notebook)
return;
-// Because of name truncation!
-#if defined(__BORLANDC__) && defined(__WIN16__)
- wxNotebookEvent event(wxEVT_COMMAND_NB_PAGE_CHANGED, m_notebook->GetId());
-#else
wxNotebookEvent event(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED, m_notebook->GetId());
-#endif
#if defined (__WIN16__)
int activatePos = activateId;