8288分类目录 8288分类目录 8288分类目录
  当前位置:海洋目录网 » 站长资讯 » 站长资讯 » 文章详细 订阅RssFeed

Action 相关组件

来源:本站原创 浏览:127次 时间:2021-09-10
Action 相关组件    


TAction //<- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTActionList //<- TCustomActionList <- TComponent//其父类 TCustomActionList 包含一个 TContainedAction 类型的动作列表(Actions[])TActionManager //<- TCustomActionManager <- TCustomActionList <- TComponent)//其父父类 TCustomActionList 包含一个 TContainedAction 类型的动作列表(Actions[])TCustomizeDlg //<- TComponent//它拥有 ActionManager: TCustomActionManager 属性TActionToolBar //<- TCustomActionToolBar <- TCustomActionDockBar <- TCustomActionBar <- TToolWindow <<<- TComponent//其父父父类 TCustomActionBar 拥有 ActionManager: TCustomActionManager 属性.TActionMainMenuBar //<- TCustomActionMainMenuBar <- TCustomActionMenuBar <- TCustomActionDockBar <- TCustomActionBar <- TToolWindow <<<- TComponent//其父父父父类 TCustomActionBar 拥有 ActionManager: TCustomActionManager 属性.TMenuItem //<- TComponent//它拥有 Action: TBasicAction 属性TPopupActionBar //<- TPopupMenu <- TMenu <- TComponent//它内部拥有 FActionManager: TCustomActionManager 成员{ StdActns 单元一些更具体的类: }THintAction   //<- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTEditAction   //<- TAction <- TCustomAction <- TContainedAction <- TBasicAction  TEditCut、TEditCopy、TEditPaste、TEditSelectAll、TEditUndo、TEditDelete、TEditSelectAll、TEditSelectAllTWindowAction //<- TAction <- TCustomAction <- TContainedAction <- TBasicAction  TWindowClose、TWindowCascade、TWindowTileHorizontal、TWindowTileVertical、TWindowMinimizeAll、TWindowArrangeTHelpAction   //<- TAction <- TCustomAction <- TContainedAction <- TBasicAction  THelpContents、THelpTopicSearch、THelpOnHelp、THelpContextActionTFileAction   //<- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction  TFileOpenWith、TFileSaveAs、TFilePrintSetup、TFilePageSetup、TFileExitTSearchFind      //<- TSearchAction <- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTSearchReplace   //<- TSearchAction <- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTSearchFindFirst //<- TSearchFind <- TSearchAction <- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTSearchFindNext  //<- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTFontEdit        //<- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTColorSelect     //<- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTPrintDlg        //<- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction <- TComponentTBrowseForFolder //<- TCommonDialogAction <- TCustomAction <- TContainedAction <- TBasicAction <- TComponent{ 另有 ExtActns 单元下的: }TFileRun、TRichEditAction、TRichEditBold、TRichEditItalic、TRichEditUnderline、TRichEditStrikeOut、TRichEditStrikeOut、TRichEditBullets、TRichEditAlignLeft、TRichEditAlignRight、TRichEditAlignCenter、TTabAction、TPreviousTab、TNextTab、TOpenPicture、TSavePicture、TURLAction、TBrowseURL、TDownLoadURL、TSendMail{ DBActns 单元下的: }TDataSetAction、TDataSetFirst、TDataSetPrior、TDataSetNext、TDataSetLast、TDataSetInsert、TDataSetDelete、TDataSetEdit、TDataSetPost、TDataSetCancel、TDataSetRefresh{ ActnRes 单元下的: }TStandardActions//它们一般用在窗体设计时


使用 TBrowseURL 打开网页:



uses ExtActns;procedure TForm1.Button1Click(Sender: TObject);begin  with TBrowseURL.Create(nil) do  begin    URL := 'http://del.cnblogs.com';    Execute;    Free;  end;end;


关联 TBrowseURL 到 TSpeedButton:



uses ExtActns, Buttons;var  bUrl: TBrowseURL;  sBtn: TSpeedButton;procedure TForm1.FormCreate(Sender: TObject);begin  bUrl := TBrowseURL.Create(Self);  bUrl.URL := 'http://del.cnblogs.com';  bUrl.Caption := 'Open URL';  sBtn := TSpeedButton.Create(Self);  sBtn.Parent := Self;  sBtn.Width := 100;  sBtn.Action := bUrl;end;


使用 TDownLoadURL 下载文件:



unit Unit1;interfaceuses  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,  Dialogs, StdCtrls, ExtActns, ComCtrls;type  TForm1 = class(TForm)    Button1: TButton;    ProgressBar1: TProgressBar;    procedure Button1Click(Sender: TObject);  private    procedure DownProgress(Sender: TDownLoadURL; Progress, ProgressMax: Cardinal;      StatusCode: TURLDownloadStatus; StatusText: String; var Cancel: Boolean);  public  end;var  Form1: TForm1;implementation{$R *.dfm}procedure TForm1.Button1Click(Sender: TObject);begin  Button1.Enabled := False;  with TDownLoadURL.Create(nil) do  begin    URL := 'http://files.cnblogs.com/del/PMark_1.rar';    Filename := 'c:\temp\PMark_1.rar';    OnDownloadProgress := DownProgress; //下载进度    ExecuteTarget(nil);    Free;  end;  Button1.Enabled := True;end;procedure TForm1.Down�߻�,ı��Progress(Sender: TDownLoadURL; Progress, ProgressMax: Cardinal;  StatusCode: TURLDownloadStatus; StatusText: String; var Cancel: Boolean);begin  ProgressBar1.Max := ProgressMax;  ProgressBar1.Position := Progress;  Application.ProcessMessages;end;end.


  推荐站点

  • At-lib分类目录At-lib分类目录

    At-lib网站分类目录汇集全国所有高质量网站,是中国权威的中文网站分类目录,给站长提供免费网址目录提交收录和推荐最新最全的优秀网站大全是名站导航之家

    www.at-lib.cn
  • 中国链接目录中国链接目录

    中国链接目录简称链接目录,是收录优秀网站和淘宝网店的网站分类目录,为您提供优质的网址导航服务,也是网店进行收录推广,站长免费推广网站、加快百度收录、增加友情链接和网站外链的平台。

    www.cnlink.org
  • 35目录网35目录网

    35目录免费收录各类优秀网站,全力打造互动式网站目录,提供网站分类目录检索,关键字搜索功能。欢迎您向35目录推荐、提交优秀网站。

    www.35mulu.com
  • 就要爱网站目录就要爱网站目录

    就要爱网站目录,按主题和类别列出网站。所有提交的网站都经过人工审查,确保质量和无垃圾邮件的结果。

    www.912219.com
  • 伍佰目录伍佰目录

    伍佰网站目录免费收录各类优秀网站,全力打造互动式网站目录,提供网站分类目录检索,关键字搜索功能。欢迎您向伍佰目录推荐、提交优秀网站。

    www.wbwb.net