Make wxNewId() and others return/take wxWindowID rather than int

wxWindowID is a typedef of int, so nothing should really change, except
for the improved readability.

Closes https://github.com/wxWidgets/wxWidgets/pull/1682
This commit is contained in:
Lauri Nurmi
2019-12-18 00:21:09 +02:00
committed by Vadim Zeitlin
parent fdc2e1b8bd
commit e8b8b0288f
3 changed files with 10 additions and 9 deletions

View File

@@ -15,6 +15,7 @@
// headers
// ----------------------------------------------------------------------------
#include "wx/windowid.h"
#include "wx/object.h"
#include "wx/list.h"
#include "wx/filefn.h"
@@ -274,13 +275,13 @@ inline bool wxPlatformIs(int platform) { return wxPlatform::Is(platform); }
// ----------------------------------------------------------------------------
// Ensure subsequent IDs don't clash with this one
WXDLLIMPEXP_BASE void wxRegisterId(int id);
WXDLLIMPEXP_BASE void wxRegisterId(wxWindowID id);
// Return the current ID
WXDLLIMPEXP_BASE int wxGetCurrentId();
WXDLLIMPEXP_BASE wxWindowID wxGetCurrentId();
// Generate a unique ID
WXDLLIMPEXP_BASE int wxNewId();
WXDLLIMPEXP_BASE wxWindowID wxNewId();
// ----------------------------------------------------------------------------
// Various conversions