X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8853b9a80e58b01a77700cb28c560ba3c1b033ce..d44d0cbd7343e36ddd3657dd97cd5eb7018d2585:/include/wx/msw/ole/uuid.h?ds=sidebyside diff --git a/include/wx/msw/ole/uuid.h b/include/wx/msw/ole/uuid.h index 2dee9946aa..44ac1cb0df 100644 --- a/include/wx/msw/ole/uuid.h +++ b/include/wx/msw/ole/uuid.h @@ -2,7 +2,7 @@ // Name: ole/uuid.h // Purpose: encapsulates an UUID with some added helper functions // Author: Vadim Zeitlin -// Modified by: +// Modified by: // Created: 11.07.97 // RCS-ID: $Id$ // Copyright: (c) 1998 Vadim Zeitlin @@ -14,10 +14,10 @@ #ifndef _WX_OLEUUID_H #define _WX_OLEUUID_H -#ifdef __GNUG__ +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma interface "uuid.h" #endif - +#include "wx/wxchar.h" // ------------------------------------------------------------------ // UUID (Universally Unique IDentifier) definition // ------------------------------------------------------------------ @@ -25,15 +25,13 @@ // ----- taken from RPC.H #ifndef UUID_DEFINED // in some cases RPC.H will be already #ifdef __WIN32__ // included, so avoid redefinition - typedef struct + typedef struct { unsigned long Data1; unsigned short Data2; unsigned short Data3; unsigned char Data4[8]; } UUID; // UUID = GUID = CLSID = LIBID = IID - #else // WIN16 - #error "Don't know about UUIDs on this platform" #endif // WIN32 #endif // UUID_DEFINED @@ -53,8 +51,8 @@ class WXDLLEXPORT Uuid { private: UUID m_uuid; - uchar *m_pszUuid; // this string is alloc'd and freed by RPC - char *m_pszCForm; // this string is allocated in Set/Create + wxUChar *m_pszUuid; // this string is alloc'd and freed by RPC + wxChar *m_pszCForm; // this string is allocated in Set/Create void UuidToCForm(); @@ -64,7 +62,7 @@ private: public: // ctors & dtor Uuid() { Init(); } - Uuid(const char *pc) { Init(); Set(pc); } + Uuid(const wxChar *pc) { Init(); Set(pc); } Uuid(const UUID &uuid) { Init(); Set(uuid); } ~Uuid(); @@ -75,17 +73,17 @@ public: // create a brand new UUID void Create(); - // set value of UUID - bool Set(const char *pc); // from a string, returns true if ok + // set value of UUID + bool Set(const wxChar *pc); // from a string, returns true if ok void Set(const UUID& uuid); // from another UUID (never fails) // accessors - operator const UUID*() const { return &m_uuid; } - operator const char*() const { return (char *)(m_pszUuid); } + operator const UUID*() const { return &m_uuid; } + operator const wxChar*() const { return (wxChar *)(m_pszUuid); } // return string representation of the UUID in the C form // (as in DEFINE_GUID macro) - const char *CForm() const { return m_pszCForm; } + const wxChar *CForm() const { return m_pszCForm; } }; #endif //_WX_OLEUUID_H