make sure that wxNewId() doesn't return standard ID's value

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30302 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2004-11-05 21:10:45 +00:00
parent 34158fee38
commit c838b68e83

View File

@@ -547,9 +547,12 @@ bool wxYieldIfNeeded()
// Id generation // Id generation
static long wxCurrentId = 100; static long wxCurrentId = 100;
long long wxNewId()
wxNewId (void)
{ {
// skip the part of IDs space that contains hard-coded values:
if (wxCurrentId == wxID_LOWEST)
wxCurrentId = wxID_HIGHEST + 1;
return wxCurrentId++; return wxCurrentId++;
} }