OSDN Git Service

Merge branch 'feature/#36529_SlimDXからSharpDXへの移行' into develop
[dtxmania/dtxmania.git] / SlimDXc_Jun2010(VC++2008) / source / ComObjectMacros.h
diff --git a/SlimDXc_Jun2010(VC++2008)/source/ComObjectMacros.h b/SlimDXc_Jun2010(VC++2008)/source/ComObjectMacros.h
deleted file mode 100644 (file)
index ea3aa20..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-/*\r
-* Copyright (c) 2007-2010 SlimDX Group\r
-* \r
-* Permission is hereby granted, free of charge, to any person obtaining a copy\r
-* of this software and associated documentation files (the "Software"), to deal\r
-* in the Software without restriction, including without limitation the rights\r
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\r
-* copies of the Software, and to permit persons to whom the Software is\r
-* furnished to do so, subject to the following conditions:\r
-* \r
-* The above copyright notice and this permission notice shall be included in\r
-* all copies or substantial portions of the Software.\r
-* \r
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\r
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\r
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\r
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\r
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\r
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\r
-* THE SOFTWARE.\r
-*/\r
-\r
-#undef COMOBJECT\r
-#undef COMOBJECT_BASE\r
-#undef COMOBJECT_CUSTOM\r
-\r
-#define COMOBJECT_BASE(nativeType) \\r
-       public: \\r
-               static property System::Guid NativeInterface { System::Guid get() { return Utilities::ConvertNativeGuid( IID_ ## nativeType ); } } \\r
-               property nativeType* InternalPointer { nativeType* get() new { return static_cast<nativeType*>( UnknownPointer ); } } \\r
-       private:\r
-\r
-// This macro provides the basic infrastructure for SlimDX ComObject subclasses. \r
-#define COMOBJECT(nativeType, managedType) \\r
-       public protected: \\r
-               managedType( nativeType* pointer, ComObject^ owner ) { Construct( pointer, owner ); } \\r
-               managedType( System::IntPtr pointer ) { Construct( pointer, NativeInterface ); } \\r
-       internal: \\r
-               static managedType^ FromPointerReflectionThunk( System::IntPtr pointer ) { return FromPointer( static_cast<nativeType*>( pointer.ToPointer() ) ); } \\r
-               static managedType^ FromPointerReflectionThunk( System::IntPtr pointer, ComObject^ owner ) { return FromPointer( static_cast<nativeType*>( pointer.ToPointer()), owner ); } \\r
-               static managedType^ FromPointer( nativeType* pointer ) { return FromPointer( pointer, nullptr, ComObjectFlags::None ); } \\r
-               static managedType^ FromPointer( nativeType* pointer, ComObject^ owner ) { return FromPointer( pointer, owner, ComObjectFlags::None ); } \\r
-               static managedType^ FromPointer( nativeType* pointer, ComObject^ owner, ComObjectFlags flags ) { return ConstructFromPointer<managedType,nativeType>( pointer, owner, flags ); } \\r
-       public: \\r
-               static managedType^ FromPointer( System::IntPtr pointer ) { return ConstructFromUserPointer<managedType>( pointer ); } \\r
-       COMOBJECT_BASE(nativeType)\r
-\r
-// This macro provides the basic infrastructure for SlimDX ComObject subclasses, but allows\r
-// the subclass to customize the behavior of the creation process for that subclass. This macro\r
-// should be applied instead of the regular COMOBJECT() macro when such customization is required.\r
-// The subclass must provide a body for the following methods:\r
-//   * managedType( nativeType* pointer, ComObject^ owner )\r
-//   * managedType( System::IntPtr pointer )\r
-//   * managedType^ FromPointer( nativeType* pointer, ComObject^ owner, ComObjectFlags flags )\r
-//   * managedType^ FromPointer( System::IntPtr pointer )\r
-//\r
-// Partial specialization is not supported; if the subclass needs special behavior for only\r
-// a subset of the above methods, it must still implement all of them, copying the standard\r
-// implementation from the COMOBJECT() macro for the appropriate non-specialized methods.\r
-#define COMOBJECT_CUSTOM(nativeType, managedType) \\r
-       public protected: \\r
-               managedType( nativeType* pointer, ComObject^ owner ); \\r
-               managedType( System::IntPtr pointer ); \\r
-       internal: \\r
-               static managedType^ FromPointer( nativeType* pointer ) { return FromPointer( pointer, nullptr, ComObjectFlags::None ); } \\r
-               static managedType^ FromPointer( nativeType* pointer, ComObject^ owner ) { return FromPointer( pointer, owner, ComObjectFlags::None ); } \\r
-               static managedType^ FromPointer( nativeType* pointer, ComObject^ owner, ComObjectFlags flags ); \\r
-       public: \\r
-               static managedType^ FromPointer( System::IntPtr pointer ); \\r
-       COMOBJECT_BASE(nativeType)\r