📄 frxdaceditor.pas
字号:
{******************************************}
{ }
{ FastReport v3.20 }
{ DAC components design editors }
{ }
// Created by: Devart
// E-mail: support@devart.com
{ }
{******************************************}
unit frxDACEditor;
interface
{$I frx.inc}
uses
Windows, Classes, SysUtils, Forms, Dialogs, frxDACComponents, frxCustomDB,
frxDsgnIntf, frxRes
{$IFDEF Delphi6}
, Variants
{$ENDIF};
type
TfrxDatabaseProperty = class(TfrxComponentProperty)
public
function GetValue: String; override;
end;
TfrxTableNameProperty = class(TfrxStringProperty)
public
function GetAttributes: TfrxPropertyAttributes; override;
procedure SetValue(const Value: String); override;
end;
implementation
{ TfrxDatabaseProperty }
function TfrxDatabaseProperty.GetValue: String;
var
db: TfrxDACDatabase;
begin
db := TfrxDACDatabase(GetOrdValue);
if db = nil then
begin
if (DACComponents <> nil) and (DACComponents.DefaultDatabase <> nil) then
Result := DACComponents.DefaultDatabase.Name
else
Result := frxResources.Get('prNotAssigned');
end
else
Result := inherited GetValue;
end;
{ TfrxTableNameProperty }
function TfrxTableNameProperty.GetAttributes: TfrxPropertyAttributes;
begin
Result := [paMultiSelect, paValueList, paSortList];
end;
procedure TfrxTableNameProperty.SetValue(const Value: String);
begin
inherited;
Designer.UpdateDataTree;
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -