projects
/
wxWidgets.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
wxTaskBarIcon::OnXXX virtual methods are deprecated, document it
[wxWidgets.git]
/
src
/
univ
/
notebook.cpp
diff --git
a/src/univ/notebook.cpp
b/src/univ/notebook.cpp
index 9e5116fe85b53d7bdd8aa44c1f72a863dac43108..68e2ec2e236bd2c0eb04a289d276e27b0cf849e3 100644
(file)
--- a/
src/univ/notebook.cpp
+++ b/
src/univ/notebook.cpp
@@
-17,10
+17,14
@@
// headers
// ----------------------------------------------------------------------------
// headers
// ----------------------------------------------------------------------------
-#if
def __GNUG__
+#if
defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
#pragma implementation "univnotebook.h"
#endif
#pragma implementation "univnotebook.h"
#endif
+#ifdef __VMS
+#pragma message disable unscomzer
+#endif
+
#include "wx/wxprec.h"
#ifdef __BORLANDC__
#include "wx/wxprec.h"
#ifdef __BORLANDC__
@@
-40,7
+44,12
@@
// macros
// ----------------------------------------------------------------------------
// macros
// ----------------------------------------------------------------------------
-#define IS_VALID_PAGE(nPage) (((nPage) >= 0) && ((nPage) < GetPageCount()))
+#if 0
+// due to unsigned type nPage is always >= 0
+#define IS_VALID_PAGE(nPage) (((nPage) >= 0) && ((size_t(nPage)) < GetPageCount()))
+#else
+#define IS_VALID_PAGE(nPage) ((size_t(nPage)) < GetPageCount())
+#endif
// ----------------------------------------------------------------------------
// constants
// ----------------------------------------------------------------------------
// constants
@@
-133,14
+142,14
@@
bool wxNotebook::Create(wxWindow *parent,
// wxNotebook page titles and images
// ----------------------------------------------------------------------------
// wxNotebook page titles and images
// ----------------------------------------------------------------------------
-wxString wxNotebook::GetPageText(
in
t nPage) const
+wxString wxNotebook::GetPageText(
size_
t nPage) const
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), _T(""), _T("invalid notebook page") );
return m_titles[nPage];
}
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), _T(""), _T("invalid notebook page") );
return m_titles[nPage];
}
-bool wxNotebook::SetPageText(
in
t nPage, const wxString& strText)
+bool wxNotebook::SetPageText(
size_
t nPage, const wxString& strText)
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), FALSE, _T("invalid notebook page") );
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), FALSE, _T("invalid notebook page") );
@@
-163,14
+172,14
@@
bool wxNotebook::SetPageText(int nPage, const wxString& strText)
return TRUE;
}
return TRUE;
}
-int wxNotebook::GetPageImage(
in
t nPage) const
+int wxNotebook::GetPageImage(
size_
t nPage) const
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), -1, _T("invalid notebook page") );
return m_images[nPage];
}
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), -1, _T("invalid notebook page") );
return m_images[nPage];
}
-bool wxNotebook::SetPageImage(
in
t nPage, int nImage)
+bool wxNotebook::SetPageImage(
size_
t nPage, int nImage)
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), FALSE, _T("invalid notebook page") );
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), FALSE, _T("invalid notebook page") );
@@
-202,7
+211,7
@@
wxNotebook::~wxNotebook()
// wxNotebook page switching
// ----------------------------------------------------------------------------
// wxNotebook page switching
// ----------------------------------------------------------------------------
-int wxNotebook::SetSelection(
in
t nPage)
+int wxNotebook::SetSelection(
size_
t nPage)
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), -1, _T("invalid notebook page") );
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), -1, _T("invalid notebook page") );
@@
-277,13
+286,13
@@
int wxNotebook::SetSelection(int nPage)
// wxNotebook pages adding/deleting
// ----------------------------------------------------------------------------
// wxNotebook pages adding/deleting
// ----------------------------------------------------------------------------
-bool wxNotebook::InsertPage(
in
t nPage,
+bool wxNotebook::InsertPage(
size_
t nPage,
wxNotebookPage *pPage,
const wxString& strText,
bool bSelect,
int imageId)
{
wxNotebookPage *pPage,
const wxString& strText,
bool bSelect,
int imageId)
{
-
in
t nPages = GetPageCount();
+
size_
t nPages = GetPageCount();
wxCHECK_MSG( nPage == nPages || IS_VALID_PAGE(nPage), FALSE,
_T("invalid notebook page in InsertPage()") );
wxCHECK_MSG( nPage == nPages || IS_VALID_PAGE(nPage), FALSE,
_T("invalid notebook page in InsertPage()") );
@@
-360,7
+369,7
@@
bool wxNotebook::DeleteAllPages()
return TRUE;
}
return TRUE;
}
-wxNotebookPage *wxNotebook::DoRemovePage(
in
t nPage)
+wxNotebookPage *wxNotebook::DoRemovePage(
size_
t nPage)
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), NULL, _T("invalid notebook page") );
{
wxCHECK_MSG( IS_VALID_PAGE(nPage), NULL, _T("invalid notebook page") );
@@
-381,7
+390,7
@@
wxNotebookPage *wxNotebook::DoRemovePage(int nPage)
UpdateSpinBtn();
}
UpdateSpinBtn();
}
-
in
t count = GetPageCount();
+
size_
t count = GetPageCount();
if ( count )
{
if ( m_sel == (size_t)nPage )
if ( count )
{
if ( m_sel == (size_t)nPage )