5,931
社区成员




unit Unit4;
interface
uses
Dialogs;
type
tbs = class(TObject)
protected
procedure show;
end;
tone = class(tbs)
protected
end;
implementation
{ tbs }
procedure tbs.show;
begin
ShowMessage('s');
end;
end.
unit Unit3;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, Unit4, RzButton;
type
TForm3 = class(TForm)
RzButton1: TRzButton;
procedure RzButton1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form3: TForm3;
implementation
{$R *.dfm}
type
THack = class(tbs);
procedure TForm3.RzButton1Click(Sender: TObject);
var
a: tone;
begin
a := tone.Create;
THack(a).show; //显示s
a.Free;
end;
end.
type
THackBsPlugin = class(TBsPlugin);
调用:
var
a: TPluginOne;
begin
a := TPluginOne.Create;
THackBsPlugin(a).ShowM(xxx);
a.Free;
end;