📄 superlegendlib_tlb.pas
字号:
property ParentShowHint;
property PopupMenu;
property ShowHint;
property TabOrder;
property Visible;
property OnDragDrop;
property OnDragOver;
property OnEndDrag;
property OnEnter;
property OnExit;
property OnStartDrag;
property OnMouseUp;
property OnMouseMove;
property OnMouseDown;
property OnDblClick;
property OnClick;
property Font: TFont index 2 read GetTFontProp write SetTFontProp stored False;
property BackColor: TColor index 1 read GetTColorProp write SetTColorProp stored False;
property Appearance: Smallint index -520 read GetSmallintProp write SetSmallintProp stored False;
property ForeColor: TColor index 3 read GetTColorProp write SetTColorProp stored False;
property OnItemSelected: TSuperLegendListItemSelected read FOnItemSelected write FOnItemSelected;
end;
// *********************************************************************//
// OLE Control Proxy class declaration
// Control Name : TSuperLegendComboBox
// Help String : SuperLegendComboBox Control
// Default Interface: _DSuperLegendComboBox
// Def. Intf. DISP? : Yes
// Event Interface: _DSuperLegendComboBoxEvents
// TypeFlags : (34) CanCreate Control
// *********************************************************************//
TSuperLegendComboBox = class(TOleControl)
private
FIntf: _DSuperLegendComboBox;
function GetControlInterface: _DSuperLegendComboBox;
protected
procedure CreateControl;
procedure InitControlData; override;
public
procedure AboutBox;
procedure Refresh;
function Disconnect: WordBool;
function Connect(const objSupermap: IDispatch): WordBool;
property ControlInterface: _DSuperLegendComboBox read GetControlInterface;
property DefaultInterface: _DSuperLegendComboBox read GetControlInterface;
property ReadyState: Integer index -525 read GetIntegerProp;
published
property Anchors;
property ParentFont;
property TabStop;
property Align;
property DragCursor;
property DragMode;
property ParentShowHint;
property PopupMenu;
property ShowHint;
property TabOrder;
property Visible;
property OnDragDrop;
property OnDragOver;
property OnEndDrag;
property OnEnter;
property OnExit;
property OnStartDrag;
property BackColor: TColor index 1 read GetTColorProp write SetTColorProp stored False;
property Appearance: Smallint index -520 read GetSmallintProp write SetSmallintProp stored False;
property ForeColor: TColor index 2 read GetTColorProp write SetTColorProp stored False;
property Font: TFont index -512 read GetTFontProp write SetTFontProp stored False;
end;
procedure Register;
resourcestring
dtlServerPage = 'ActiveX';
dtlOcxPage = 'ActiveX';
implementation
uses ComObj;
procedure TSuperLegend.InitControlData;
const
CEventDispIDs: array [0..2] of DWORD = (
$FFFFFD9F, $00000001, $00000002);
CLicenseKey: array[0..39] of Word = ( $0043, $006F, $0070, $0079, $0072, $0069, $0067, $0068, $0074, $0020, $0028
, $0063, $0029, $0020, $0032, $0030, $0030, $0030, $0020, $0053, $0075
, $0070, $0065, $0072, $004D, $0061, $0070, $0020, $0043, $006F, $0072
, $0070, $006F, $0072, $0061, $0074, $0069, $006F, $006E, $0000);
CTFontIDs: array [0..0] of DWORD = (
$FFFFFE00);
CControlData: TControlData2 = (
ClassID: '{AA66E1F1-5441-4596-A712-DF82705B3466}';
EventIID: '{580F9EDE-363F-4F7E-B446-AB5164539352}';
EventCount: 3;
EventDispIDs: @CEventDispIDs;
LicenseKey: @CLicenseKey;
Flags: $00000007;
Version: 401;
FontCount: 1;
FontIDs: @CTFontIDs);
begin
ControlData := @CControlData;
TControlData2(CControlData).FirstEventOfs := Cardinal(@@FOnReadyStateChange) - Cardinal(Self);
end;
procedure TSuperLegend.CreateControl;
procedure DoCreate;
begin
FIntf := IUnknown(OleObject) as _DSuperLegend;
end;
begin
if FIntf = nil then DoCreate;
end;
function TSuperLegend.GetControlInterface: _DSuperLegend;
begin
CreateControl;
Result := FIntf;
end;
procedure TSuperLegend.AboutBox;
begin
DefaultInterface.AboutBox;
end;
procedure TSuperLegend.Expand;
begin
DefaultInterface.Expand;
end;
procedure TSuperLegend.Disconnect;
begin
DefaultInterface.Disconnect;
end;
function TSuperLegend.Connect(const objSuperMapCtrl: IDispatch): WordBool;
begin
Result := DefaultInterface.Connect(objSuperMapCtrl);
end;
procedure TSuperLegend.Refresh;
begin
DefaultInterface.Refresh;
end;
function TSuperLegend.Clear: WordBool;
begin
Result := DefaultInterface.Clear;
end;
procedure TSuperLegendList.InitControlData;
const
CEventDispIDs: array [0..0] of DWORD = (
$00000001);
CTFontIDs: array [0..0] of DWORD = (
$00000002);
CControlData: TControlData2 = (
ClassID: '{13B8BE52-F47B-4146-80E6-DFE89729A37A}';
EventIID: '{08B4A4E0-9E5F-4ED7-8A7A-D0013F410E56}';
EventCount: 1;
EventDispIDs: @CEventDispIDs;
LicenseKey: nil (*HR:$80004005*);
Flags: $00000000;
Version: 401;
FontCount: 1;
FontIDs: @CTFontIDs);
begin
ControlData := @CControlData;
TControlData2(CControlData).FirstEventOfs := Cardinal(@@FOnItemSelected) - Cardinal(Self);
end;
procedure TSuperLegendList.CreateControl;
procedure DoCreate;
begin
FIntf := IUnknown(OleObject) as _DSuperLegendList;
end;
begin
if FIntf = nil then DoCreate;
end;
function TSuperLegendList.GetControlInterface: _DSuperLegendList;
begin
CreateControl;
Result := FIntf;
end;
procedure TSuperLegendList.AboutBox;
begin
DefaultInterface.AboutBox;
end;
procedure TSuperLegendList.Refresh;
begin
DefaultInterface.Refresh;
end;
function TSuperLegendList.Disconnect: WordBool;
begin
Result := DefaultInterface.Disconnect;
end;
function TSuperLegendList.Connect(const objSuperMapCtrl: IDispatch): WordBool;
begin
Result := DefaultInterface.Connect(objSuperMapCtrl);
end;
procedure TSuperLegendComboBox.InitControlData;
const
CTFontIDs: array [0..0] of DWORD = (
$FFFFFE00);
CControlData: TControlData2 = (
ClassID: '{01691B01-7B34-43BD-A547-3D6FA7455126}';
EventIID: '';
EventCount: 0;
EventDispIDs: nil;
LicenseKey: nil (*HR:$80004005*);
Flags: $00000004;
Version: 401;
FontCount: 1;
FontIDs: @CTFontIDs);
begin
ControlData := @CControlData;
end;
procedure TSuperLegendComboBox.CreateControl;
procedure DoCreate;
begin
FIntf := IUnknown(OleObject) as _DSuperLegendComboBox;
end;
begin
if FIntf = nil then DoCreate;
end;
function TSuperLegendComboBox.GetControlInterface: _DSuperLegendComboBox;
begin
CreateControl;
Result := FIntf;
end;
procedure TSuperLegendComboBox.AboutBox;
begin
DefaultInterface.AboutBox;
end;
procedure TSuperLegendComboBox.Refresh;
begin
DefaultInterface.Refresh;
end;
function TSuperLegendComboBox.Disconnect: WordBool;
begin
Result := DefaultInterface.Disconnect;
end;
function TSuperLegendComboBox.Connect(const objSupermap: IDispatch): WordBool;
begin
Result := DefaultInterface.Connect(objSupermap);
end;
procedure Register;
begin
RegisterComponents(dtlOcxPage, [TSuperLegend, TSuperLegendList, TSuperLegendComboBox]);
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -