Initial commit: Complete open-source Decal rebuild
All 5 phases of the open-source Decal rebuild: Phase 1: 14 decompiled .NET projects (Interop.*, Adapter, FileService, DecalUtil) Phase 2: 10 native DLLs rewritten as C# COM servers with matching GUIDs - DecalDat, DHS, SpellFilter, DecalInput, DecalNet, DecalFilters - Decal.Core, DecalControls, DecalRender, D3DService Phase 3: C++ shims for Inject.DLL (D3D9 hooking) and LauncherHook.DLL Phase 4: DenAgent WinForms tray application Phase 5: WiX installer and build script 25 C# projects building with 0 errors. Native C++ projects require VS 2022 + Windows SDK (x86). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
commit
d1442e3747
1382 changed files with 170725 additions and 0 deletions
|
|
@ -0,0 +1,9 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<AssemblyName>Decal.Interop.Controls</AssemblyName>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Decal.Interop.Core\Decal.Interop.Core.csproj" />
|
||||
<ProjectReference Include="..\Decal.Interop.Inject\Decal.Interop.Inject.csproj" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("6450E486-03E6-493C-9D3B-9B36A5F50E65")]
|
||||
[CoClass(typeof(BorderLayoutClass))]
|
||||
public interface BorderLayout : ILayout, IControlEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,82 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[ComSourceInterfaces("Decal.Interop.Inject.IControlEvents, Decal.Interop.Inject, Version=2.9.8.3, Culture=neutral, PublicKeyToken=481f17d392f1fb65\0\0")]
|
||||
[TypeLibType(2)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[Guid("CA121762-31BB-4073-8597-33BAB4BDCAA3")]
|
||||
public class BorderLayoutClass : ILayout, BorderLayout, IControlEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
public virtual extern IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event IControlEvents_DestroyEventHandler Destroy;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("E28573F0-36FC-4D64-B8E1-60A2D475A2A8")]
|
||||
[CoClass(typeof(CheckColumnClass))]
|
||||
public interface CheckColumn : IListColumn
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[TypeLibType(2)]
|
||||
[Guid("48E444F1-8E30-4E4C-B203-4C87FC901586")]
|
||||
public class CheckColumnClass : IListColumn, CheckColumn
|
||||
{
|
||||
[DispId(1610678272)]
|
||||
public virtual extern bool FixedWidth
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(1610678273)]
|
||||
public virtual extern int Width
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(1610678275)]
|
||||
public virtual extern int DataColumns
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(1610678278)]
|
||||
public virtual extern int Height
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void Render([MarshalAs(UnmanagedType.Interface)] Canvas __MIDL__IListColumn0000, ref tagPOINT ptCell, int nColor);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void Initialize([In][MarshalAs(UnmanagedType.Interface)] IList newVal, [In][MarshalAs(UnmanagedType.Interface)] PluginSite pSite);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void SchemaLoad([MarshalAs(UnmanagedType.IUnknown)] object pSchema);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void Activate(ref tagPOINT ptCell);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[CoClass(typeof(CheckboxClass))]
|
||||
[Guid("63D0BB56-1552-4F8C-99CC-52006DD47E9E")]
|
||||
public interface Checkbox : ICheckbox, ICheckboxEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,134 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("5AE37451-F79C-478A-834E-EDCF95F01B0E")]
|
||||
[ComSourceInterfaces("Decal.Interop.Controls.ICheckboxEvents\0\0")]
|
||||
[TypeLibType(2)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
public class CheckboxClass : ICheckbox, Checkbox, ICheckboxEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
public virtual extern IFontCache Font
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
public virtual extern string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
public virtual extern int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
public virtual extern bool Checked
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
public virtual extern bool RightToLeft
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event ICheckboxEvents_DestroyEventHandler Destroy;
|
||||
|
||||
public virtual extern event ICheckboxEvents_ChangeEventHandler Change;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[CoClass(typeof(ChoiceClass))]
|
||||
[Guid("BD2B37B8-80DE-4F50-ACF8-ED2525B27336")]
|
||||
public interface Choice : IChoice, IChoiceEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,156 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[ComSourceInterfaces("Decal.Interop.Controls.IChoiceEvents\0\0")]
|
||||
[Guid("E099DC60-0F19-4690-AB7C-8B5834DA286E")]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[TypeLibType(2)]
|
||||
public class ChoiceClass : IChoice, Choice, IChoiceEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
public virtual extern int ChoiceCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
public virtual extern object Data
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[return: MarshalAs(UnmanagedType.Struct)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Struct)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
public virtual extern string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(106)]
|
||||
public virtual extern bool Dropped
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(107)]
|
||||
public virtual extern int Selected
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(108)]
|
||||
public virtual extern int DropLines
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event IChoiceEvents_DestroyEventHandler Destroy;
|
||||
|
||||
public virtual extern event IChoiceEvents_ChangeEventHandler Change;
|
||||
|
||||
public virtual extern event IChoiceEvents_DropDownEventHandler DropDown;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
public virtual extern void AddChoice([MarshalAs(UnmanagedType.BStr)] string strDisplay, [Optional][MarshalAs(UnmanagedType.Struct)] object vData);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
public virtual extern void RemoveChoice(int nIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
public virtual extern void Clear();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("D4FBCA22-45B4-4775-A181-1D4EEC3BFEA1")]
|
||||
[CoClass(typeof(DerethMapClass))]
|
||||
public interface DerethMap : IDerethMap, ICommandEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,72 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("3035299A-C5FB-4CC7-A63C-66400B80DCA4")]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[ComSourceInterfaces("Decal.Interop.Inject.ICommandEvents, Decal.Interop.Inject, Version=2.9.8.3, Culture=neutral, PublicKeyToken=481f17d392f1fb65\0\0")]
|
||||
[TypeLibType(2)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public class DerethMapClass : IDerethMap, DerethMap, ICommandEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event ICommandEvents_DestroyEventHandler Destroy;
|
||||
|
||||
public virtual extern event ICommandEvents_HitEventHandler Hit;
|
||||
|
||||
public virtual extern event ICommandEvents_UnhitEventHandler Unhit;
|
||||
|
||||
public virtual extern event ICommandEvents_AcceptedEventHandler Accepted;
|
||||
|
||||
public virtual extern event ICommandEvents_CanceledEventHandler Canceled;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[CoClass(typeof(EditClass))]
|
||||
[Guid("D7EA9129-E36A-4317-BF24-76DA5967DA75")]
|
||||
public interface Edit : IEdit, IEditEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,166 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[TypeLibType(2)]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[Guid("8E8F88D2-AA47-474E-9DB7-912D49C8BE9D")]
|
||||
[ComSourceInterfaces("Decal.Interop.Controls.IEditEvents\0\0")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public class EditClass : IEdit, Edit, IEditEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
public virtual extern string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
public virtual extern int Caret
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
public virtual extern string SelectedText
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
public virtual extern IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(106)]
|
||||
public virtual extern IFontCache Font
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(107)]
|
||||
public virtual extern int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event IEditEvents_DestroyEventHandler Destroy;
|
||||
|
||||
public virtual extern event IEditEvents_BeginEventHandler Begin;
|
||||
|
||||
public virtual extern event IEditEvents_ChangeEventHandler Change;
|
||||
|
||||
public virtual extern event IEditEvents_EndEventHandler End;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
public virtual extern void Select(int nStart, int nEnd);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
public virtual extern void SetMargins(int nX, int nY);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
public virtual extern void Capture();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("6450E486-03E6-493C-9D3B-9B36A5F50E65")]
|
||||
[CoClass(typeof(FixedLayoutClass))]
|
||||
public interface FixedLayout : ILayout, IControlEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,82 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("CD6556CD-F8D9-4CB0-AB7C-7C33058294E4")]
|
||||
[ComSourceInterfaces("Decal.Interop.Inject.IControlEvents, Decal.Interop.Inject, Version=2.9.8.3, Culture=neutral, PublicKeyToken=481f17d392f1fb65\0\0")]
|
||||
[TypeLibType(2)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
public class FixedLayoutClass : ILayout, FixedLayout, IControlEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
public virtual extern IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event IControlEvents_DestroyEventHandler Destroy;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("CF0438EB-8299-48E8-B766-9E9BDDA50203")]
|
||||
[TypeLibType(4096)]
|
||||
public interface IBorderLayout : ILayout
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
new IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void CreateEdge(eBorderEdge eEdge, int nSize, [MarshalAs(UnmanagedType.Interface)] ILayer pSink);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void CreateCenter([MarshalAs(UnmanagedType.Interface)] ILayer pSink);
|
||||
}
|
||||
|
|
@ -0,0 +1,106 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[TypeLibType(4160)]
|
||||
[Guid("63D0BB56-1552-4F8C-99CC-52006DD47E9E")]
|
||||
public interface ICheckbox : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
IFontCache Font
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
bool Checked
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
bool RightToLeft
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("D56CB28A-9BAD-40B1-A011-70F466DC8F05")]
|
||||
[InterfaceType(2)]
|
||||
[TypeLibType(4096)]
|
||||
public interface ICheckboxEvents
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void Destroy(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
void Change(int nID, bool bChecked);
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ICheckboxEvents_ChangeEventHandler(int nID, bool bChecked);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ICheckboxEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(16)]
|
||||
[ComVisible(false)]
|
||||
public interface ICheckboxEvents_Event
|
||||
{
|
||||
event ICheckboxEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event ICheckboxEvents_ChangeEventHandler Change;
|
||||
}
|
||||
|
|
@ -0,0 +1,230 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class ICheckboxEvents_EventProvider : ICheckboxEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
138, 178, 108, 213, 173, 155, 177, 64, 160, 17,
|
||||
112, 244, 102, 220, 143, 5
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event ICheckboxEvents_DestroyEventHandler ICheckboxEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ICheckboxEvents_SinkHelper checkboxEvents_SinkHelper = new ICheckboxEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(checkboxEvents_SinkHelper, out pdwCookie);
|
||||
checkboxEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
checkboxEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(checkboxEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ICheckboxEvents_SinkHelper checkboxEvents_SinkHelper = (ICheckboxEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (checkboxEvents_SinkHelper.m_DestroyDelegate != null && ((checkboxEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(checkboxEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event ICheckboxEvents_ChangeEventHandler ICheckboxEvents_Event.Change
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ICheckboxEvents_SinkHelper checkboxEvents_SinkHelper = new ICheckboxEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(checkboxEvents_SinkHelper, out pdwCookie);
|
||||
checkboxEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
checkboxEvents_SinkHelper.m_ChangeDelegate = value;
|
||||
m_aEventSinkHelpers.Add(checkboxEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ICheckboxEvents_SinkHelper checkboxEvents_SinkHelper = (ICheckboxEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (checkboxEvents_SinkHelper.m_ChangeDelegate != null && ((checkboxEvents_SinkHelper.m_ChangeDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(checkboxEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public ICheckboxEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
ICheckboxEvents_SinkHelper checkboxEvents_SinkHelper = (ICheckboxEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(checkboxEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
public sealed class ICheckboxEvents_SinkHelper : ICheckboxEvents
|
||||
{
|
||||
public ICheckboxEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public ICheckboxEvents_ChangeEventHandler m_ChangeDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Change(int P_0, bool P_1)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_ChangeDelegate != null)
|
||||
{
|
||||
m_ChangeDelegate(P_0, P_1);
|
||||
}
|
||||
}
|
||||
|
||||
internal ICheckboxEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_ChangeDelegate = null;
|
||||
}
|
||||
}
|
||||
126
Managed/Decal.Interop.Controls/Decal.Interop.Controls/IChoice.cs
Normal file
126
Managed/Decal.Interop.Controls/Decal.Interop.Controls/IChoice.cs
Normal file
|
|
@ -0,0 +1,126 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[TypeLibType(4160)]
|
||||
[Guid("BD2B37B8-80DE-4F50-ACF8-ED2525B27336")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface IChoice : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
void AddChoice([MarshalAs(UnmanagedType.BStr)] string strDisplay, [Optional][MarshalAs(UnmanagedType.Struct)] object vData);
|
||||
|
||||
[DispId(102)]
|
||||
int ChoiceCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
object Data
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[return: MarshalAs(UnmanagedType.Struct)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Struct)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
void RemoveChoice(int nIndex);
|
||||
|
||||
[DispId(106)]
|
||||
bool Dropped
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(107)]
|
||||
int Selected
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(108)]
|
||||
int DropLines
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
void Clear();
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[InterfaceType(1)]
|
||||
[Guid("5BAD2CC0-6F03-4EA9-8D7E-1DFD9D134648")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface IChoiceDropDown
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("763E36A3-389C-42EB-A5F3-C208D028F9AB")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[InterfaceType(2)]
|
||||
[TypeLibType(4096)]
|
||||
public interface IChoiceEvents
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void Destroy(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
void Change(int nID, int nIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(12)]
|
||||
void DropDown(int nID);
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IChoiceEvents_ChangeEventHandler(int nID, int nIndex);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IChoiceEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IChoiceEvents_DropDownEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(16)]
|
||||
[ComVisible(false)]
|
||||
public interface IChoiceEvents_Event
|
||||
{
|
||||
event IChoiceEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event IChoiceEvents_ChangeEventHandler Change;
|
||||
|
||||
event IChoiceEvents_DropDownEventHandler DropDown;
|
||||
}
|
||||
|
|
@ -0,0 +1,306 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class IChoiceEvents_EventProvider : IChoiceEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
163, 54, 62, 118, 156, 56, 235, 66, 165, 243,
|
||||
194, 8, 208, 40, 249, 171
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event IChoiceEvents_DestroyEventHandler IChoiceEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IChoiceEvents_SinkHelper choiceEvents_SinkHelper = new IChoiceEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(choiceEvents_SinkHelper, out pdwCookie);
|
||||
choiceEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
choiceEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(choiceEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IChoiceEvents_SinkHelper choiceEvents_SinkHelper = (IChoiceEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (choiceEvents_SinkHelper.m_DestroyDelegate != null && ((choiceEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(choiceEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event IChoiceEvents_ChangeEventHandler IChoiceEvents_Event.Change
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IChoiceEvents_SinkHelper choiceEvents_SinkHelper = new IChoiceEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(choiceEvents_SinkHelper, out pdwCookie);
|
||||
choiceEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
choiceEvents_SinkHelper.m_ChangeDelegate = value;
|
||||
m_aEventSinkHelpers.Add(choiceEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IChoiceEvents_SinkHelper choiceEvents_SinkHelper = (IChoiceEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (choiceEvents_SinkHelper.m_ChangeDelegate != null && ((choiceEvents_SinkHelper.m_ChangeDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(choiceEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event IChoiceEvents_DropDownEventHandler IChoiceEvents_Event.DropDown
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IChoiceEvents_SinkHelper choiceEvents_SinkHelper = new IChoiceEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(choiceEvents_SinkHelper, out pdwCookie);
|
||||
choiceEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
choiceEvents_SinkHelper.m_DropDownDelegate = value;
|
||||
m_aEventSinkHelpers.Add(choiceEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IChoiceEvents_SinkHelper choiceEvents_SinkHelper = (IChoiceEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (choiceEvents_SinkHelper.m_DropDownDelegate != null && ((choiceEvents_SinkHelper.m_DropDownDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(choiceEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public IChoiceEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
IChoiceEvents_SinkHelper choiceEvents_SinkHelper = (IChoiceEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(choiceEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,52 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
public sealed class IChoiceEvents_SinkHelper : IChoiceEvents
|
||||
{
|
||||
public IChoiceEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public IChoiceEvents_ChangeEventHandler m_ChangeDelegate;
|
||||
|
||||
public IChoiceEvents_DropDownEventHandler m_DropDownDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Change(int P_0, int P_1)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_ChangeDelegate != null)
|
||||
{
|
||||
m_ChangeDelegate(P_0, P_1);
|
||||
}
|
||||
}
|
||||
|
||||
public void DropDown(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DropDownDelegate != null)
|
||||
{
|
||||
m_DropDownDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
internal IChoiceEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_ChangeDelegate = null;
|
||||
m_DropDownDelegate = null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[InterfaceType(1)]
|
||||
[Guid("B40F3CEA-5DAD-413A-B779-D6FCB0663B7D")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface IChoicePopup
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ICommandEvents_AcceptedEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ICommandEvents_CanceledEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ICommandEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,19 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(16)]
|
||||
[ComVisible(false)]
|
||||
public interface ICommandEvents_Event
|
||||
{
|
||||
event ICommandEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event ICommandEvents_HitEventHandler Hit;
|
||||
|
||||
event ICommandEvents_UnhitEventHandler Unhit;
|
||||
|
||||
event ICommandEvents_AcceptedEventHandler Accepted;
|
||||
|
||||
event ICommandEvents_CanceledEventHandler Canceled;
|
||||
}
|
||||
|
|
@ -0,0 +1,458 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class ICommandEvents_EventProvider : ICommandEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
161, 211, 41, 240, 175, 41, 239, 69, 146, 126,
|
||||
114, 159, 237, 216, 116, 3
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event ICommandEvents_DestroyEventHandler ICommandEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = new ICommandEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(commandEvents_SinkHelper, out pdwCookie);
|
||||
commandEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
commandEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(commandEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = (ICommandEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (commandEvents_SinkHelper.m_DestroyDelegate != null && ((commandEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(commandEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event ICommandEvents_HitEventHandler ICommandEvents_Event.Hit
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = new ICommandEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(commandEvents_SinkHelper, out pdwCookie);
|
||||
commandEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
commandEvents_SinkHelper.m_HitDelegate = value;
|
||||
m_aEventSinkHelpers.Add(commandEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = (ICommandEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (commandEvents_SinkHelper.m_HitDelegate != null && ((commandEvents_SinkHelper.m_HitDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(commandEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event ICommandEvents_UnhitEventHandler ICommandEvents_Event.Unhit
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = new ICommandEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(commandEvents_SinkHelper, out pdwCookie);
|
||||
commandEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
commandEvents_SinkHelper.m_UnhitDelegate = value;
|
||||
m_aEventSinkHelpers.Add(commandEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = (ICommandEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (commandEvents_SinkHelper.m_UnhitDelegate != null && ((commandEvents_SinkHelper.m_UnhitDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(commandEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event ICommandEvents_AcceptedEventHandler ICommandEvents_Event.Accepted
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = new ICommandEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(commandEvents_SinkHelper, out pdwCookie);
|
||||
commandEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
commandEvents_SinkHelper.m_AcceptedDelegate = value;
|
||||
m_aEventSinkHelpers.Add(commandEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = (ICommandEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (commandEvents_SinkHelper.m_AcceptedDelegate != null && ((commandEvents_SinkHelper.m_AcceptedDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(commandEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event ICommandEvents_CanceledEventHandler ICommandEvents_Event.Canceled
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = new ICommandEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(commandEvents_SinkHelper, out pdwCookie);
|
||||
commandEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
commandEvents_SinkHelper.m_CanceledDelegate = value;
|
||||
m_aEventSinkHelpers.Add(commandEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = (ICommandEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (commandEvents_SinkHelper.m_CanceledDelegate != null && ((commandEvents_SinkHelper.m_CanceledDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(commandEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public ICommandEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
ICommandEvents_SinkHelper commandEvents_SinkHelper = (ICommandEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(commandEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ICommandEvents_HitEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,77 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
public sealed class ICommandEvents_SinkHelper : ICommandEvents
|
||||
{
|
||||
public ICommandEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public ICommandEvents_HitEventHandler m_HitDelegate;
|
||||
|
||||
public ICommandEvents_UnhitEventHandler m_UnhitDelegate;
|
||||
|
||||
public ICommandEvents_AcceptedEventHandler m_AcceptedDelegate;
|
||||
|
||||
public ICommandEvents_CanceledEventHandler m_CanceledDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Hit(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_HitDelegate != null)
|
||||
{
|
||||
m_HitDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Unhit(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_UnhitDelegate != null)
|
||||
{
|
||||
m_UnhitDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Accepted(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_AcceptedDelegate != null)
|
||||
{
|
||||
m_AcceptedDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Canceled(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_CanceledDelegate != null)
|
||||
{
|
||||
m_CanceledDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
internal ICommandEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_HitDelegate = null;
|
||||
m_UnhitDelegate = null;
|
||||
m_AcceptedDelegate = null;
|
||||
m_CanceledDelegate = null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ICommandEvents_UnhitEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IControlEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(16)]
|
||||
[ComVisible(false)]
|
||||
public interface IControlEvents_Event
|
||||
{
|
||||
event IControlEvents_DestroyEventHandler Destroy;
|
||||
}
|
||||
|
|
@ -0,0 +1,154 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class IControlEvents_EventProvider : IControlEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
195, 203, 235, 47, 140, 72, 79, 68, 173, 8,
|
||||
93, 48, 151, 210, 209, 237
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event IControlEvents_DestroyEventHandler IControlEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IControlEvents_SinkHelper controlEvents_SinkHelper = new IControlEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(controlEvents_SinkHelper, out pdwCookie);
|
||||
controlEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
controlEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(controlEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IControlEvents_SinkHelper controlEvents_SinkHelper = (IControlEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (controlEvents_SinkHelper.m_DestroyDelegate != null && ((controlEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(controlEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public IControlEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
IControlEvents_SinkHelper controlEvents_SinkHelper = (IControlEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(controlEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
public sealed class IControlEvents_SinkHelper : IControlEvents
|
||||
{
|
||||
public IControlEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
internal IControlEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[TypeLibType(4096)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("D4FBCA22-45B4-4775-A181-1D4EEC3BFEA1")]
|
||||
public interface IDerethMap : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
}
|
||||
134
Managed/Decal.Interop.Controls/Decal.Interop.Controls/IEdit.cs
Normal file
134
Managed/Decal.Interop.Controls/Decal.Interop.Controls/IEdit.cs
Normal file
|
|
@ -0,0 +1,134 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("D7EA9129-E36A-4317-BF24-76DA5967DA75")]
|
||||
[TypeLibType(4160)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface IEdit : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
int Caret
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
void Select(int nStart, int nEnd);
|
||||
|
||||
[DispId(104)]
|
||||
string SelectedText
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(106)]
|
||||
IFontCache Font
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(107)]
|
||||
int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
void SetMargins(int nX, int nY);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
void Capture();
|
||||
}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[InterfaceType(2)]
|
||||
[Guid("4A3E384D-39A5-4BC2-A548-66634C8FACCE")]
|
||||
[TypeLibType(4096)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface IEditEvents
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void Destroy(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(10)]
|
||||
void Begin(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
void Change(int nID, [MarshalAs(UnmanagedType.BStr)] string strText);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(11)]
|
||||
void End(int nID, bool bSuccess);
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IEditEvents_BeginEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IEditEvents_ChangeEventHandler(int nID, [MarshalAs(UnmanagedType.BStr)] string strText);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IEditEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IEditEvents_EndEventHandler(int nID, bool bSuccess);
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(16)]
|
||||
[ComVisible(false)]
|
||||
public interface IEditEvents_Event
|
||||
{
|
||||
event IEditEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event IEditEvents_BeginEventHandler Begin;
|
||||
|
||||
event IEditEvents_ChangeEventHandler Change;
|
||||
|
||||
event IEditEvents_EndEventHandler End;
|
||||
}
|
||||
|
|
@ -0,0 +1,382 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class IEditEvents_EventProvider : IEditEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
77, 56, 62, 74, 165, 57, 194, 75, 165, 72,
|
||||
102, 99, 76, 143, 172, 206
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event IEditEvents_DestroyEventHandler IEditEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = new IEditEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(editEvents_SinkHelper, out pdwCookie);
|
||||
editEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
editEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(editEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = (IEditEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (editEvents_SinkHelper.m_DestroyDelegate != null && ((editEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(editEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event IEditEvents_BeginEventHandler IEditEvents_Event.Begin
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = new IEditEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(editEvents_SinkHelper, out pdwCookie);
|
||||
editEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
editEvents_SinkHelper.m_BeginDelegate = value;
|
||||
m_aEventSinkHelpers.Add(editEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = (IEditEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (editEvents_SinkHelper.m_BeginDelegate != null && ((editEvents_SinkHelper.m_BeginDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(editEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event IEditEvents_ChangeEventHandler IEditEvents_Event.Change
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = new IEditEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(editEvents_SinkHelper, out pdwCookie);
|
||||
editEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
editEvents_SinkHelper.m_ChangeDelegate = value;
|
||||
m_aEventSinkHelpers.Add(editEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = (IEditEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (editEvents_SinkHelper.m_ChangeDelegate != null && ((editEvents_SinkHelper.m_ChangeDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(editEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event IEditEvents_EndEventHandler IEditEvents_Event.End
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = new IEditEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(editEvents_SinkHelper, out pdwCookie);
|
||||
editEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
editEvents_SinkHelper.m_EndDelegate = value;
|
||||
m_aEventSinkHelpers.Add(editEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = (IEditEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (editEvents_SinkHelper.m_EndDelegate != null && ((editEvents_SinkHelper.m_EndDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(editEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public IEditEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
IEditEvents_SinkHelper editEvents_SinkHelper = (IEditEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(editEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,64 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
public sealed class IEditEvents_SinkHelper : IEditEvents
|
||||
{
|
||||
public IEditEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public IEditEvents_BeginEventHandler m_BeginDelegate;
|
||||
|
||||
public IEditEvents_ChangeEventHandler m_ChangeDelegate;
|
||||
|
||||
public IEditEvents_EndEventHandler m_EndDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Begin(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_BeginDelegate != null)
|
||||
{
|
||||
m_BeginDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Change(int P_0, string P_1)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_ChangeDelegate != null)
|
||||
{
|
||||
m_ChangeDelegate(P_0, P_1);
|
||||
}
|
||||
}
|
||||
|
||||
public void End(int P_0, bool P_1)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_EndDelegate != null)
|
||||
{
|
||||
m_EndDelegate(P_0, P_1);
|
||||
}
|
||||
}
|
||||
|
||||
internal IEditEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_BeginDelegate = null;
|
||||
m_ChangeDelegate = null;
|
||||
m_EndDelegate = null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,57 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Core;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("58CBF550-DFBE-433C-88EC-3FED4A5E09F1")]
|
||||
[TypeLibType(4096)]
|
||||
public interface IFixedLayout : ILayout
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
new IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void CreateChild(ref LayerParams @params, [MarshalAs(UnmanagedType.Interface)] ILayer pSink);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void PositionChild(int nID, ref tagRECT prcNew);
|
||||
}
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[TypeLibType(4160)]
|
||||
[Guid("6450E486-03E6-493C-9D3B-9B36A5F50E65")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface ILayout : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
}
|
||||
137
Managed/Decal.Interop.Controls/Decal.Interop.Controls/IList.cs
Normal file
137
Managed/Decal.Interop.Controls/Decal.Interop.Controls/IList.cs
Normal file
|
|
@ -0,0 +1,137 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Core;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("D648F00A-FE27-4E88-895B-72F58AF50C0C")]
|
||||
[TypeLibType(4096)]
|
||||
public interface IList : IListDisp
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new int AddRow();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DeleteRow(int nIndex);
|
||||
|
||||
[DispId(103)]
|
||||
new object Data
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Struct)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Struct)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
new int RowEstimate
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
new int Count
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void Clear();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void InsertRow(int lIndex);
|
||||
|
||||
[DispId(108)]
|
||||
new int ColumnWidth
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(109)]
|
||||
new int Color
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(110)]
|
||||
new bool AutoScroll
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(111)]
|
||||
new int ScrollPosition
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void JumpToPosition(int newVal);
|
||||
|
||||
[DispId(113)]
|
||||
new int CountCols
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
int AddColumn([MarshalAs(UnmanagedType.Interface)] IListColumn pNewColumn);
|
||||
|
||||
[DispId(1610874881)]
|
||||
tagRECT CellRect
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[InterfaceType(1)]
|
||||
[Guid("E28573F0-36FC-4D64-B8E1-60A2D475A2A8")]
|
||||
public interface IListColumn
|
||||
{
|
||||
[DispId(1610678272)]
|
||||
bool FixedWidth
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(1610678273)]
|
||||
int Width
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Render([MarshalAs(UnmanagedType.Interface)] Canvas __MIDL__IListColumn0000, ref tagPOINT ptCell, int nColor);
|
||||
|
||||
[DispId(1610678275)]
|
||||
int DataColumns
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Initialize([In][MarshalAs(UnmanagedType.Interface)] IList newVal, [In][MarshalAs(UnmanagedType.Interface)] PluginSite pSite);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SchemaLoad([MarshalAs(UnmanagedType.IUnknown)] object pSchema);
|
||||
|
||||
[DispId(1610678278)]
|
||||
int Height
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Activate(ref tagPOINT ptCell);
|
||||
}
|
||||
|
|
@ -0,0 +1,148 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[TypeLibType(4160)]
|
||||
[Guid("A54D70F6-8CFE-4259-9F16-AF0111541278")]
|
||||
public interface IListDisp : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
int AddRow();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
void DeleteRow(int nIndex);
|
||||
|
||||
[DispId(103)]
|
||||
object Data
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[return: MarshalAs(UnmanagedType.Struct)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Struct)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
int RowEstimate
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
int Count
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
void Clear();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
void InsertRow(int lIndex);
|
||||
|
||||
[DispId(108)]
|
||||
int ColumnWidth
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(109)]
|
||||
int Color
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(110)]
|
||||
bool AutoScroll
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(110)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(110)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(111)]
|
||||
int ScrollPosition
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(111)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(111)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(112)]
|
||||
void JumpToPosition(int newVal);
|
||||
|
||||
[DispId(113)]
|
||||
int CountCols
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(113)]
|
||||
get;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("88456660-8132-433B-A4CD-E252BDF147C5")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[InterfaceType(2)]
|
||||
[TypeLibType(4096)]
|
||||
public interface IListEvents
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void Destroy(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
void Change(int nID, int nX, int nY);
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IListEvents_ChangeEventHandler(int nID, int nX, int nY);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IListEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(16)]
|
||||
[ComVisible(false)]
|
||||
public interface IListEvents_Event
|
||||
{
|
||||
event IListEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event IListEvents_ChangeEventHandler Change;
|
||||
}
|
||||
|
|
@ -0,0 +1,230 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class IListEvents_EventProvider : IListEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
96, 102, 69, 136, 50, 129, 59, 67, 164, 205,
|
||||
226, 82, 189, 241, 71, 197
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event IListEvents_DestroyEventHandler IListEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IListEvents_SinkHelper listEvents_SinkHelper = new IListEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(listEvents_SinkHelper, out pdwCookie);
|
||||
listEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
listEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(listEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IListEvents_SinkHelper listEvents_SinkHelper = (IListEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (listEvents_SinkHelper.m_DestroyDelegate != null && ((listEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(listEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event IListEvents_ChangeEventHandler IListEvents_Event.Change
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IListEvents_SinkHelper listEvents_SinkHelper = new IListEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(listEvents_SinkHelper, out pdwCookie);
|
||||
listEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
listEvents_SinkHelper.m_ChangeDelegate = value;
|
||||
m_aEventSinkHelpers.Add(listEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IListEvents_SinkHelper listEvents_SinkHelper = (IListEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (listEvents_SinkHelper.m_ChangeDelegate != null && ((listEvents_SinkHelper.m_ChangeDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(listEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public IListEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
IListEvents_SinkHelper listEvents_SinkHelper = (IListEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(listEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
public sealed class IListEvents_SinkHelper : IListEvents
|
||||
{
|
||||
public IListEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public IListEvents_ChangeEventHandler m_ChangeDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Change(int P_0, int P_1, int P_2)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_ChangeDelegate != null)
|
||||
{
|
||||
m_ChangeDelegate(P_0, P_1, P_2);
|
||||
}
|
||||
}
|
||||
|
||||
internal IListEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_ChangeDelegate = null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[InterfaceType(1)]
|
||||
[Guid("1A11BEA0-A0ED-41C1-9057-46084DE9AEDC")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[ComConversionLoss]
|
||||
public interface IListView
|
||||
{
|
||||
[DispId(1610678272)]
|
||||
IntPtr Area
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetCacheInfo(int nRowHeight, int nRowsToCache);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void InvalidateFrom(int nRow);
|
||||
|
||||
[DispId(1610678275)]
|
||||
int Color
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,72 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("78B62B0F-B3A4-47FF-A9A4-C68CA3FA80B6")]
|
||||
[TypeLibType(4160)]
|
||||
public interface INotebook : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
void AddPage([MarshalAs(UnmanagedType.BStr)] string strText, [MarshalAs(UnmanagedType.Interface)] IControl pClient);
|
||||
|
||||
[DispId(102)]
|
||||
int ActiveTab
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
string PageText
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[TypeLibType(4096)]
|
||||
[Guid("C964E99A-7C1C-46E9-AEA6-09FF5D1BFDD0")]
|
||||
[InterfaceType(2)]
|
||||
public interface INotebookEvents
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void Destroy(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
void Change(int nID, int nNewPage);
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void INotebookEvents_ChangeEventHandler(int nID, int nNewPage);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void INotebookEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[TypeLibType(16)]
|
||||
[ComVisible(false)]
|
||||
public interface INotebookEvents_Event
|
||||
{
|
||||
event INotebookEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event INotebookEvents_ChangeEventHandler Change;
|
||||
}
|
||||
|
|
@ -0,0 +1,230 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class INotebookEvents_EventProvider : INotebookEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
154, 233, 100, 201, 28, 124, 233, 70, 174, 166,
|
||||
9, 255, 93, 27, 253, 208
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event INotebookEvents_DestroyEventHandler INotebookEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
INotebookEvents_SinkHelper notebookEvents_SinkHelper = new INotebookEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(notebookEvents_SinkHelper, out pdwCookie);
|
||||
notebookEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
notebookEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(notebookEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
INotebookEvents_SinkHelper notebookEvents_SinkHelper = (INotebookEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (notebookEvents_SinkHelper.m_DestroyDelegate != null && ((notebookEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(notebookEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event INotebookEvents_ChangeEventHandler INotebookEvents_Event.Change
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
INotebookEvents_SinkHelper notebookEvents_SinkHelper = new INotebookEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(notebookEvents_SinkHelper, out pdwCookie);
|
||||
notebookEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
notebookEvents_SinkHelper.m_ChangeDelegate = value;
|
||||
m_aEventSinkHelpers.Add(notebookEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
INotebookEvents_SinkHelper notebookEvents_SinkHelper = (INotebookEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (notebookEvents_SinkHelper.m_ChangeDelegate != null && ((notebookEvents_SinkHelper.m_ChangeDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(notebookEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public INotebookEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
INotebookEvents_SinkHelper notebookEvents_SinkHelper = (INotebookEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(notebookEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
public sealed class INotebookEvents_SinkHelper : INotebookEvents
|
||||
{
|
||||
public INotebookEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public INotebookEvents_ChangeEventHandler m_ChangeDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Change(int P_0, int P_1)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_ChangeDelegate != null)
|
||||
{
|
||||
m_ChangeDelegate(P_0, P_1);
|
||||
}
|
||||
}
|
||||
|
||||
internal INotebookEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_ChangeDelegate = null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,70 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[TypeLibType(4096)]
|
||||
[Guid("2DF39739-2EFC-4F67-B3AC-712D774B57A9")]
|
||||
public interface IPageLayout : IPageLayoutDisp
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
new IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(201)]
|
||||
new int Active
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(202)]
|
||||
new int Count
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void CreatePage([MarshalAs(UnmanagedType.Interface)] ILayer pChild);
|
||||
}
|
||||
|
|
@ -0,0 +1,76 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("1E39FB9E-2C07-4287-B2D7-58EE0BFC9BBB")]
|
||||
[TypeLibType(4160)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface IPageLayoutDisp : ILayout
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
new IImageCache Background
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(201)]
|
||||
int Active
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(201)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(201)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(202)]
|
||||
int Count
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(202)]
|
||||
get;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,147 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("2EC89916-3E65-422B-977C-9277BA693E82")]
|
||||
[TypeLibType(4160)]
|
||||
public interface IProgress : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
int Value
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
int FaceColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
int FillColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
int MaxValue
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(106)]
|
||||
string PostText
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(107)]
|
||||
string Alignment
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(108)]
|
||||
bool DecalDrawText
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(109)]
|
||||
string PreText
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(110)]
|
||||
int BorderWidth
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(110)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(111)]
|
||||
int BorderColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(111)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,108 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[TypeLibType(4160)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("AAAB9EEA-06E8-4F0A-A926-3A9AB45939FF")]
|
||||
public interface IPushButton : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
IImageCache Image
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
IFontCache Font
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
int FaceColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,104 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[TypeLibType(4096)]
|
||||
[Guid("24CFCE12-88A0-437A-89E6-31982EA92899")]
|
||||
public interface IScroller : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(1610809344)]
|
||||
tagSIZE Viewport
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(1610809345)]
|
||||
tagSIZE Area
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(1610809347)]
|
||||
bool HorizontalEnabled
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(1610809349)]
|
||||
bool VerticalEnabled
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void CreateClient([MarshalAs(UnmanagedType.Interface)] ILayer pChild);
|
||||
|
||||
[DispId(1610809352)]
|
||||
tagPOINT Offset
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void ScrollTo(ref tagPOINT ptOffset);
|
||||
|
||||
[DispId(1610809355)]
|
||||
tagSIZE Increments
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void ResetScroller();
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[TypeLibType(4096)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[InterfaceType(2)]
|
||||
[Guid("DEE67370-16C9-4F81-80CC-1F1B61112299")]
|
||||
public interface IScrollerEvents
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void Destroy(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
void Change(int nID, int nX, int nY);
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IScrollerEvents_ChangeEventHandler(int nID, int nX, int nY);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void IScrollerEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
[TypeLibType(16)]
|
||||
public interface IScrollerEvents_Event
|
||||
{
|
||||
event IScrollerEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event IScrollerEvents_ChangeEventHandler Change;
|
||||
}
|
||||
|
|
@ -0,0 +1,230 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class IScrollerEvents_EventProvider : IScrollerEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
112, 115, 230, 222, 201, 22, 129, 79, 128, 204,
|
||||
31, 27, 97, 17, 34, 153
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event IScrollerEvents_DestroyEventHandler IScrollerEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IScrollerEvents_SinkHelper scrollerEvents_SinkHelper = new IScrollerEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(scrollerEvents_SinkHelper, out pdwCookie);
|
||||
scrollerEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
scrollerEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(scrollerEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IScrollerEvents_SinkHelper scrollerEvents_SinkHelper = (IScrollerEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (scrollerEvents_SinkHelper.m_DestroyDelegate != null && ((scrollerEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(scrollerEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event IScrollerEvents_ChangeEventHandler IScrollerEvents_Event.Change
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
IScrollerEvents_SinkHelper scrollerEvents_SinkHelper = new IScrollerEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(scrollerEvents_SinkHelper, out pdwCookie);
|
||||
scrollerEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
scrollerEvents_SinkHelper.m_ChangeDelegate = value;
|
||||
m_aEventSinkHelpers.Add(scrollerEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
IScrollerEvents_SinkHelper scrollerEvents_SinkHelper = (IScrollerEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (scrollerEvents_SinkHelper.m_ChangeDelegate != null && ((scrollerEvents_SinkHelper.m_ChangeDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(scrollerEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public IScrollerEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
IScrollerEvents_SinkHelper scrollerEvents_SinkHelper = (IScrollerEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(scrollerEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
public sealed class IScrollerEvents_SinkHelper : IScrollerEvents
|
||||
{
|
||||
public IScrollerEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public IScrollerEvents_ChangeEventHandler m_ChangeDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Change(int P_0, int P_1, int P_2)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_ChangeDelegate != null)
|
||||
{
|
||||
m_ChangeDelegate(P_0, P_1, P_2);
|
||||
}
|
||||
}
|
||||
|
||||
internal IScrollerEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_ChangeDelegate = null;
|
||||
}
|
||||
}
|
||||
104
Managed/Decal.Interop.Controls/Decal.Interop.Controls/ISlider.cs
Normal file
104
Managed/Decal.Interop.Controls/Decal.Interop.Controls/ISlider.cs
Normal file
|
|
@ -0,0 +1,104 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("10D12549-8F59-4F06-83FB-D08FB76337F3")]
|
||||
[TypeLibType(4160)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface ISlider : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
IFontCache Font
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
int SliderPosition
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
int Minimum
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(106)]
|
||||
int Maximum
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[InterfaceType(2)]
|
||||
[TypeLibType(4096)]
|
||||
[Guid("F881B44D-67FA-4770-B10A-05DA14409E8F")]
|
||||
public interface ISliderEvents
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void Destroy(int nID);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
void Change(int nID, int lValue);
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ISliderEvents_ChangeEventHandler(int nID, int lValue);
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
public delegate void ISliderEvents_DestroyEventHandler(int nID);
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComVisible(false)]
|
||||
[TypeLibType(16)]
|
||||
public interface ISliderEvents_Event
|
||||
{
|
||||
event ISliderEvents_DestroyEventHandler Destroy;
|
||||
|
||||
event ISliderEvents_ChangeEventHandler Change;
|
||||
}
|
||||
|
|
@ -0,0 +1,230 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Threading;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
internal sealed class ISliderEvents_EventProvider : ISliderEvents_Event, IDisposable
|
||||
{
|
||||
private IConnectionPointContainer m_ConnectionPointContainer;
|
||||
|
||||
private ArrayList m_aEventSinkHelpers;
|
||||
|
||||
private IConnectionPoint m_ConnectionPoint;
|
||||
|
||||
private void Init()
|
||||
{
|
||||
IConnectionPoint ppCP = null;
|
||||
Guid riid = new Guid(new byte[16]
|
||||
{
|
||||
77, 180, 129, 248, 250, 103, 112, 71, 177, 10,
|
||||
5, 218, 20, 64, 158, 143
|
||||
});
|
||||
m_ConnectionPointContainer.FindConnectionPoint(ref riid, out ppCP);
|
||||
m_ConnectionPoint = ppCP;
|
||||
m_aEventSinkHelpers = new ArrayList();
|
||||
}
|
||||
|
||||
event ISliderEvents_DestroyEventHandler ISliderEvents_Event.Destroy
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ISliderEvents_SinkHelper sliderEvents_SinkHelper = new ISliderEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(sliderEvents_SinkHelper, out pdwCookie);
|
||||
sliderEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
sliderEvents_SinkHelper.m_DestroyDelegate = value;
|
||||
m_aEventSinkHelpers.Add(sliderEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ISliderEvents_SinkHelper sliderEvents_SinkHelper = (ISliderEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (sliderEvents_SinkHelper.m_DestroyDelegate != null && ((sliderEvents_SinkHelper.m_DestroyDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(sliderEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
event ISliderEvents_ChangeEventHandler ISliderEvents_Event.Change
|
||||
{
|
||||
add
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
Init();
|
||||
}
|
||||
ISliderEvents_SinkHelper sliderEvents_SinkHelper = new ISliderEvents_SinkHelper();
|
||||
int pdwCookie = 0;
|
||||
m_ConnectionPoint.Advise(sliderEvents_SinkHelper, out pdwCookie);
|
||||
sliderEvents_SinkHelper.m_dwCookie = pdwCookie;
|
||||
sliderEvents_SinkHelper.m_ChangeDelegate = value;
|
||||
m_aEventSinkHelpers.Add(sliderEvents_SinkHelper);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
remove
|
||||
{
|
||||
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_aEventSinkHelpers == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 >= count)
|
||||
{
|
||||
return;
|
||||
}
|
||||
do
|
||||
{
|
||||
ISliderEvents_SinkHelper sliderEvents_SinkHelper = (ISliderEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
if (sliderEvents_SinkHelper.m_ChangeDelegate != null && ((sliderEvents_SinkHelper.m_ChangeDelegate.Equals(value) ? 1u : 0u) & 0xFFu) != 0)
|
||||
{
|
||||
m_aEventSinkHelpers.RemoveAt(num);
|
||||
m_ConnectionPoint.Unadvise(sliderEvents_SinkHelper.m_dwCookie);
|
||||
if (count <= 1)
|
||||
{
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
m_ConnectionPoint = null;
|
||||
m_aEventSinkHelpers = null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public ISliderEvents_EventProvider(object P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_ConnectionPointContainer = (IConnectionPointContainer)P_0;
|
||||
}
|
||||
|
||||
public void Finalize()
|
||||
{
|
||||
bool lockTaken = default(bool);
|
||||
try
|
||||
{
|
||||
Monitor.Enter(this, ref lockTaken);
|
||||
if (m_ConnectionPoint == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
int count = m_aEventSinkHelpers.Count;
|
||||
int num = 0;
|
||||
if (0 < count)
|
||||
{
|
||||
do
|
||||
{
|
||||
ISliderEvents_SinkHelper sliderEvents_SinkHelper = (ISliderEvents_SinkHelper)m_aEventSinkHelpers[num];
|
||||
m_ConnectionPoint.Unadvise(sliderEvents_SinkHelper.m_dwCookie);
|
||||
num++;
|
||||
}
|
||||
while (num < count);
|
||||
}
|
||||
Marshal.ReleaseComObject(m_ConnectionPoint);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (lockTaken)
|
||||
{
|
||||
Monitor.Exit(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
Finalize();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[TypeLibType(TypeLibTypeFlags.FHidden)]
|
||||
public sealed class ISliderEvents_SinkHelper : ISliderEvents
|
||||
{
|
||||
public ISliderEvents_DestroyEventHandler m_DestroyDelegate;
|
||||
|
||||
public ISliderEvents_ChangeEventHandler m_ChangeDelegate;
|
||||
|
||||
public int m_dwCookie;
|
||||
|
||||
public void Destroy(int P_0)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_DestroyDelegate != null)
|
||||
{
|
||||
m_DestroyDelegate(P_0);
|
||||
}
|
||||
}
|
||||
|
||||
public void Change(int P_0, int P_1)
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
if (m_ChangeDelegate != null)
|
||||
{
|
||||
m_ChangeDelegate(P_0, P_1);
|
||||
}
|
||||
}
|
||||
|
||||
internal ISliderEvents_SinkHelper()
|
||||
{
|
||||
//Error decoding local variables: Signature type sequence must have at least one element.
|
||||
m_dwCookie = 0;
|
||||
m_DestroyDelegate = null;
|
||||
m_ChangeDelegate = null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,82 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("93C28CFF-DCF4-4B63-AB00-A89453940CFE")]
|
||||
[TypeLibType(4160)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public interface IStatic : IControl
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
new void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[DispId(2)]
|
||||
new int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
new int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
new IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(101)]
|
||||
IFontCache Font
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
string Text
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
int TextColor
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[CoClass(typeof(IconColumnClass))]
|
||||
[Guid("E28573F0-36FC-4D64-B8E1-60A2D475A2A8")]
|
||||
public interface IconColumn : IListColumn
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
[Guid("F12A2C4C-3B78-46EB-8722-68B27A75AE55")]
|
||||
[TypeLibType(2)]
|
||||
public class IconColumnClass : IListColumn, IconColumn
|
||||
{
|
||||
[DispId(1610678272)]
|
||||
public virtual extern bool FixedWidth
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(1610678273)]
|
||||
public virtual extern int Width
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(1610678275)]
|
||||
public virtual extern int DataColumns
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(1610678278)]
|
||||
public virtual extern int Height
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void Render([MarshalAs(UnmanagedType.Interface)] Canvas __MIDL__IListColumn0000, ref tagPOINT ptCell, int nColor);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void Initialize([In][MarshalAs(UnmanagedType.Interface)] IList newVal, [In][MarshalAs(UnmanagedType.Interface)] PluginSite pSite);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void SchemaLoad([MarshalAs(UnmanagedType.IUnknown)] object pSchema);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void Activate(ref tagPOINT ptCell);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[CoClass(typeof(ListClass))]
|
||||
[Guid("A54D70F6-8CFE-4259-9F16-AF0111541278")]
|
||||
public interface List : IListDisp, IListEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,176 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[TypeLibType(2)]
|
||||
[ComSourceInterfaces("Decal.Interop.Controls.IListEvents\0\0")]
|
||||
[Guid("3839008F-AF5B-43FC-9F6A-3376B99E3DAF")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public class ListClass : IListDisp, List, IListEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
public virtual extern object Data
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[return: MarshalAs(UnmanagedType.Struct)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Struct)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(104)]
|
||||
public virtual extern int RowEstimate
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(104)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(105)]
|
||||
public virtual extern int Count
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(105)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(108)]
|
||||
public virtual extern int ColumnWidth
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(108)]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(109)]
|
||||
public virtual extern int Color
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(109)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(110)]
|
||||
public virtual extern bool AutoScroll
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(110)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(110)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(111)]
|
||||
public virtual extern int ScrollPosition
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(111)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(111)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(113)]
|
||||
public virtual extern int CountCols
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(113)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event IListEvents_DestroyEventHandler Destroy;
|
||||
|
||||
public virtual extern event IListEvents_ChangeEventHandler Change;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
public virtual extern int AddRow();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
public virtual extern void DeleteRow(int nIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(106)]
|
||||
public virtual extern void Clear();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(107)]
|
||||
public virtual extern void InsertRow(int lIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(112)]
|
||||
public virtual extern void JumpToPosition(int newVal);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("78B62B0F-B3A4-47FF-A9A4-C68CA3FA80B6")]
|
||||
[CoClass(typeof(NotebookClass))]
|
||||
public interface Notebook : INotebook, INotebookEvents_Event
|
||||
{
|
||||
}
|
||||
|
|
@ -0,0 +1,100 @@
|
|||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security;
|
||||
using Decal.Interop.Inject;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[ComSourceInterfaces("Decal.Interop.Controls.INotebookEvents\0\0")]
|
||||
[TypeLibType(2)]
|
||||
[ClassInterface(ClassInterfaceType.None)]
|
||||
[Guid("ED14E7C5-11BE-4DFD-9829-873AB6BE3CFC")]
|
||||
[SuppressUnmanagedCodeSecurity]
|
||||
public class NotebookClass : INotebook, Notebook, INotebookEvents_Event, IControl
|
||||
{
|
||||
[DispId(2)]
|
||||
public virtual extern int ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(3)]
|
||||
public virtual extern int ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(4)]
|
||||
public virtual extern IControl Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
[DispId(102)]
|
||||
public virtual extern int ActiveTab
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(102)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(103)]
|
||||
public virtual extern string PageText
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(103)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ID
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern int IControl_ChildCount
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern IControl IControl_Child
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
}
|
||||
|
||||
public virtual extern event INotebookEvents_DestroyEventHandler Destroy;
|
||||
|
||||
public virtual extern event INotebookEvents_ChangeEventHandler Change;
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
public virtual extern void DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(101)]
|
||||
public virtual extern void AddPage([MarshalAs(UnmanagedType.BStr)] string strText, [MarshalAs(UnmanagedType.Interface)] IControl pClient);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
public virtual extern void IControl_DestroyChild(int nIndex, ePositionType posType = ePositionType.ePositionByIndex);
|
||||
}
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Decal.Interop.Controls;
|
||||
|
||||
[ComImport]
|
||||
[Guid("1E39FB9E-2C07-4287-B2D7-58EE0BFC9BBB")]
|
||||
[CoClass(typeof(PageLayoutClass))]
|
||||
public interface PageLayout : IPageLayoutDisp, IControlEvents_Event
|
||||
{
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue