projects
/
wxWidgets.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
the manual contained wrong licence wording inconsistent with any other sources, inclu...
[wxWidgets.git]
/
src
/
common
/
list.cpp
diff --git
a/src/common/list.cpp
b/src/common/list.cpp
index e51c3640211a2ed321e9673ef296352fcd76f82e..28f4148c7b17d53976b4a2298a9b2fee98b625ba 100644
(file)
--- a/
src/common/list.cpp
+++ b/
src/common/list.cpp
@@
-147,7
+147,7
@@
void wxListBase::Init(wxKeyType keyType)
m_nodeFirst =
m_nodeLast = (wxNodeBase *) NULL;
m_count = 0;
m_nodeFirst =
m_nodeLast = (wxNodeBase *) NULL;
m_count = 0;
- m_destroy =
FALSE
;
+ m_destroy =
false
;
m_keyType = keyType;
}
m_keyType = keyType;
}
@@
-408,11
+408,11
@@
wxNodeBase *wxListBase::DetachNode(wxNodeBase *node)
bool wxListBase::DeleteNode(wxNodeBase *node)
{
if ( !DetachNode(node) )
bool wxListBase::DeleteNode(wxNodeBase *node)
{
if ( !DetachNode(node) )
- return
FALSE
;
+ return
false
;
DoDeleteNode(node);
DoDeleteNode(node);
- return
TRUE
;
+ return
true
;
}
bool wxListBase::DeleteObject(void *object)
}
bool wxListBase::DeleteObject(void *object)
@@
-422,12
+422,12
@@
bool wxListBase::DeleteObject(void *object)
if ( current->GetData() == object )
{
DeleteNode(current);
if ( current->GetData() == object )
{
DeleteNode(current);
- return
TRUE
;
+ return
true
;
}
}
// not found
}
}
// not found
- return
FALSE
;
+ return
false
;
}
void wxListBase::Clear()
}
void wxListBase::Clear()
@@
-624,12
+624,12
@@
bool wxStringList::Delete(const wxChar *s)
if ( wxStrcmp(current->GetData(), s) == 0 )
{
DeleteNode(current);
if ( wxStrcmp(current->GetData(), s) == 0 )
{
DeleteNode(current);
- return
TRUE
;
+ return
true
;
}
}
// not found
}
}
// not found
- return
FALSE
;
+ return
false
;
}
void wxStringList::DoCopy(const wxStringList& other)
}
void wxStringList::DoCopy(const wxStringList& other)
@@
-645,14
+645,14
@@
void wxStringList::DoCopy(const wxStringList& other)
wxStringList::wxStringList()
{
wxStringList::wxStringList()
{
- DeleteContents(
TRUE
);
+ DeleteContents(
true
);
}
// Variable argument list, terminated by a zero
// Makes new storage for the strings
wxStringList::wxStringList (const wxChar *first, ...)
{
}
// Variable argument list, terminated by a zero
// Makes new storage for the strings
wxStringList::wxStringList (const wxChar *first, ...)
{
- DeleteContents(
TRUE
);
+ DeleteContents(
true
);
if ( !first )
return;
if ( !first )
return;
@@
-677,7
+677,7
@@
wxStringList::wxStringList (const wxChar *first, ...)
va_end(ap);
}
va_end(ap);
}
-// Only makes new strings if arg is
TRUE
+// Only makes new strings if arg is
true
wxChar **wxStringList::ListToArray(bool new_copies) const
{
wxChar **string_array = new wxChar *[GetCount()];
wxChar **wxStringList::ListToArray(bool new_copies) const
{
wxChar **string_array = new wxChar *[GetCount()];
@@
-702,10
+702,10
@@
bool wxStringList::Member(const wxChar *s) const
{
const wxChar *s1 = node->GetData();
if (s == s1 || wxStrcmp (s, s1) == 0)
{
const wxChar *s1 = node->GetData();
if (s == s1 || wxStrcmp (s, s1) == 0)
- return
TRUE
;
+ return
true
;
}
}
- return
FALSE
;
+ return
false
;
}
#ifdef __WXWINCE__
}
#ifdef __WXWINCE__
@@
-748,7
+748,7
@@
wxNode *wxStringList::Add(const wxChar *s)
{
return (wxNode *)wxStringListBase::Append(MYcopystring(s));
}
{
return (wxNode *)wxStringListBase::Append(MYcopystring(s));
}
-
+
wxNode *wxStringList::Prepend(const wxChar *s)
{
return (wxNode *)wxStringListBase::Insert(MYcopystring(s));
wxNode *wxStringList::Prepend(const wxChar *s)
{
return (wxNode *)wxStringListBase::Insert(MYcopystring(s));
@@
-756,4
+756,15
@@
wxNode *wxStringList::Prepend(const wxChar *s)
#endif // wxLIST_COMPATIBILITY
#endif // wxLIST_COMPATIBILITY
+#else // wxUSE_STL = 1
+
+ #include <wx/listimpl.cpp>
+ WX_DEFINE_LIST(wxObjectList);
+
+// with wxUSE_STL wxStringList contains wxString objects, not pointers
+void wxStringListBase::DeleteFunction( const wxString WXUNUSED(X) )
+{
+}
+
#endif // !wxUSE_STL
#endif // !wxUSE_STL
+