X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cf2810aa394d47a43489d6138edf0497c389a22c..66c2bf7b1d9326fb650acfaae22ec50528cfbf7c:/include/wx/windowid.h?ds=inline diff --git a/include/wx/windowid.h b/include/wx/windowid.h index 4b2e3e171c..0c174b5f0c 100644 --- a/include/wx/windowid.h +++ b/include/wx/windowid.h @@ -3,7 +3,6 @@ // Purpose: wxWindowID class - a class for managing window ids // Author: Brian Vanderburg II // Created: 2007-09-21 -// RCS-ID: $Id$ // Copyright: (c) 2007 Brian Vanderburg II // Licence: wxWindows licence /////////////////////////////////////////////////////////////////////////////// @@ -43,7 +42,7 @@ public: wxWindowIDRef(long id) { - Init(id); + Init(wxWindowID(id)); } wxWindowIDRef(const wxWindowIDRef& id) @@ -66,13 +65,14 @@ public: wxWindowIDRef& operator=(long id) { - Assign(id); + Assign(wxWindowID(id)); return *this; } wxWindowIDRef& operator=(const wxWindowIDRef& id) { - Assign(id.m_id); + if (&id != this) + Assign(id.m_id); return *this; }