⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 s2.form.ts2dialogfactory.pas

📁 轉載的程序應用框架
💻 PAS
字号:
unit S2.Form.TS2DialogFactory;

interface

uses
  S2.View.TS2View, S2.Form.TS2Dialog, S2.Form.TS2ViewDialog;

type
  TS2DialogFactory = class
  public
    class function GetDialog(View: TS2View): TS2ViewDialog; virtual;
    class function GetMessageDialog(const Messgae: string): TS2Dialog; virtual;
    class function GetSavePromptDialog: TS2Dialog; virtual;
    class procedure ShowMessage(const Message: string);
  end;

implementation

uses
  S2.View.TS2DataItemView, S2.View.TS2DataItemsView, S2.Form.TS2DataItemViewDialog, S2.Form.TS2DataItemsViewDialog,
  S2.View.TS2AdapterDataItemsView, S2.Model.TS2SystemObject;

{ TS2DialogFactory }

class function TS2DialogFactory.GetDialog(View: TS2View): TS2ViewDialog;
begin
  if View is TS2AdapterDataItemsView then
  if View is TS2DataItemView then
    Result := TS2DataItemViewDialog.Create(GetGlobalSystemObject, GetGlobalSystemObject)
  else if View is TS2DataItemsView then
    Result := TS2DataItemsViewDialog.Create(GetGlobalSystemObject, GetGlobalSystemObject);                                   
end;

class function TS2DialogFactory.GetMessageDialog(const Messgae: string): TS2Dialog;
begin

end;

class function TS2DialogFactory.GetSavePromptDialog: TS2Dialog;
begin

end;

class procedure TS2DialogFactory.ShowMessage(const Message: string);
begin

end;

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -