You've already forked lazarus-ccr
tvplanit: Remove not-working property and component editors by an IFDEF from regristration.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@4786 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -62,6 +62,7 @@ type
|
|||||||
procedure GetValues(Proc: TGetStrProc); override;
|
procedure GetValues(Proc: TGetStrProc); override;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
{$IFDEF DELPHI}
|
||||||
{TAliasNameProperty}
|
{TAliasNameProperty}
|
||||||
TAliasNameProperty = class(TDBStringProperty)
|
TAliasNameProperty = class(TDBStringProperty)
|
||||||
public
|
public
|
||||||
@ -82,6 +83,7 @@ type
|
|||||||
public
|
public
|
||||||
procedure GetValues(Proc: TGetStrProc); override;
|
procedure GetValues(Proc: TGetStrProc); override;
|
||||||
end;
|
end;
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
TVpDateProperty = class (TFloatProperty)
|
TVpDateProperty = class (TFloatProperty)
|
||||||
public
|
public
|
||||||
@ -167,16 +169,6 @@ uses
|
|||||||
VpFlxDSEd1; { Field mapper component editor for the FlexDS }
|
VpFlxDSEd1; { Field mapper component editor for the FlexDS }
|
||||||
|
|
||||||
|
|
||||||
(*****************************************************************************)
|
|
||||||
{ TAliasNameProperty }
|
|
||||||
|
|
||||||
procedure TAliasNameProperty.GetValueList(List: TStrings);
|
|
||||||
begin
|
|
||||||
{$IFDEF DELPHI}
|
|
||||||
(GetComponent(0) as TVpBDEDataStore).Database.Session.GetAliasNames(List);
|
|
||||||
{$ENDIF}
|
|
||||||
end;
|
|
||||||
|
|
||||||
(*****************************************************************************)
|
(*****************************************************************************)
|
||||||
{ TDBStringProperty }
|
{ TDBStringProperty }
|
||||||
|
|
||||||
@ -206,16 +198,22 @@ begin
|
|||||||
end;
|
end;
|
||||||
{=====}
|
{=====}
|
||||||
|
|
||||||
|
{$IFDEF DELPHI}
|
||||||
|
(*****************************************************************************)
|
||||||
|
{ TAliasNameProperty }
|
||||||
|
|
||||||
|
procedure TAliasNameProperty.GetValueList(List: TStrings);
|
||||||
|
begin
|
||||||
|
(GetComponent(0) as TVpBDEDataStore).Database.Session.GetAliasNames(List);
|
||||||
|
end;
|
||||||
|
|
||||||
(*****************************************************************************)
|
(*****************************************************************************)
|
||||||
{ TDriverNameProperty }
|
{ TDriverNameProperty }
|
||||||
|
|
||||||
procedure TDriverNameProperty.GetValueList(List: TStrings);
|
procedure TDriverNameProperty.GetValueList(List: TStrings);
|
||||||
begin
|
begin
|
||||||
{$IFDEF DELPHI}
|
|
||||||
(GetComponent(0) as TVpBDEDataStore).Database.Session.GetDriverNames(List);
|
(GetComponent(0) as TVpBDEDataStore).Database.Session.GetDriverNames(List);
|
||||||
{$ENDIF}
|
|
||||||
end;
|
end;
|
||||||
{=====}
|
|
||||||
|
|
||||||
(*****************************************************************************)
|
(*****************************************************************************)
|
||||||
{ TDataStoreProperty }
|
{ TDataStoreProperty }
|
||||||
@ -224,13 +222,11 @@ var
|
|||||||
J: Integer;
|
J: Integer;
|
||||||
DataStore: TVpCustomDataStore;
|
DataStore: TVpCustomDataStore;
|
||||||
begin
|
begin
|
||||||
{$IFDEF DELPHI}
|
|
||||||
DataStore := TVpCustomDataStore(Designer.GetComponent(Value));
|
DataStore := TVpCustomDataStore(Designer.GetComponent(Value));
|
||||||
for J := 0 to PropCount - 1 do
|
for J := 0 to PropCount - 1 do
|
||||||
if TVpDayView(GetComponent(J)).DataStore = DataStore then
|
if TVpDayView(GetComponent(J)).DataStore = DataStore then
|
||||||
Exit;
|
Exit;
|
||||||
FCheckProc(Value);
|
FCheckProc(Value);
|
||||||
{$ENDIF}
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TDataStoreProperty.GetValues(Proc: TGetStrProc);
|
procedure TDataStoreProperty.GetValues(Proc: TGetStrProc);
|
||||||
@ -239,14 +235,13 @@ begin
|
|||||||
inherited GetValues(CheckComponent);
|
inherited GetValues(CheckComponent);
|
||||||
end;
|
end;
|
||||||
{=====}
|
{=====}
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
(*****************************************************************************)
|
(*****************************************************************************)
|
||||||
{ TDataStoreProperty }
|
{ TVpDateProperty }
|
||||||
procedure TVpDateProperty.Edit;
|
procedure TVpDateProperty.Edit;
|
||||||
|
|
||||||
var
|
var
|
||||||
frmDatePropertyEditor: TfrmDatePropertyEditor;
|
frmDatePropertyEditor: TfrmDatePropertyEditor;
|
||||||
|
|
||||||
begin
|
begin
|
||||||
frmDatePropertyEditor := TfrmDatePropertyEditor.Create (Application);
|
frmDatePropertyEditor := TfrmDatePropertyEditor.Create (Application);
|
||||||
try
|
try
|
||||||
@ -259,8 +254,6 @@ begin
|
|||||||
end;
|
end;
|
||||||
{=====}
|
{=====}
|
||||||
|
|
||||||
(*****************************************************************************)
|
|
||||||
{ TVpDateProperty }
|
|
||||||
function TVpDateProperty.GetAttributes : TPropertyAttributes;
|
function TVpDateProperty.GetAttributes : TPropertyAttributes;
|
||||||
begin
|
begin
|
||||||
Result := [paDialog, paMultiSelect];
|
Result := [paDialog, paMultiSelect];
|
||||||
@ -413,13 +406,19 @@ end;
|
|||||||
{*** component registration ***}
|
{*** component registration ***}
|
||||||
procedure Register;
|
procedure Register;
|
||||||
begin
|
begin
|
||||||
|
{----------------------------------------------------------------------------}
|
||||||
{ register component editors }
|
{ register component editors }
|
||||||
|
{----------------------------------------------------------------------------}
|
||||||
{$IFDEF DELPHI}
|
{$IFDEF DELPHI}
|
||||||
RegisterComponentEditor(TVpNavBar, TVpNavBarEditor);
|
RegisterComponentEditor(TVpNavBar, TVpNavBarEditor);
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
RegisterComponentEditor(TVpControlLink, TVpPrtFmtPropertyEditor);
|
RegisterComponentEditor(TVpControlLink, TVpPrtFmtPropertyEditor);
|
||||||
RegisterComponentEditor(TVpFlexDataStore, TVpFlexDSEditor);
|
RegisterComponentEditor(TVpFlexDataStore, TVpFlexDSEditor);
|
||||||
|
|
||||||
|
{----------------------------------------------------------------------------}
|
||||||
|
{ register property editors }
|
||||||
|
{----------------------------------------------------------------------------}
|
||||||
|
|
||||||
{ register the About Box property editor for the Version properties }
|
{ register the About Box property editor for the Version properties }
|
||||||
RegisterPropertyEditor(TypeInfo(string), TVpCollectionItem,
|
RegisterPropertyEditor(TypeInfo(string), TVpCollectionItem,
|
||||||
'Version', TVpAboutProperty);
|
'Version', TVpAboutProperty);
|
||||||
@ -439,6 +438,8 @@ begin
|
|||||||
'Version', TVpAboutProperty);
|
'Version', TVpAboutProperty);
|
||||||
RegisterPropertyEditor(TypeInfo(string), TVpControlLink,
|
RegisterPropertyEditor(TypeInfo(string), TVpControlLink,
|
||||||
'Version', TVpAboutProperty);
|
'Version', TVpAboutProperty);
|
||||||
|
|
||||||
|
{ Other property editors }
|
||||||
{$IFDEF DELPHI}
|
{$IFDEF DELPHI}
|
||||||
RegisterPropertyEditor(TypeInfo(string), TVpBDEDataStore,
|
RegisterPropertyEditor(TypeInfo(string), TVpBDEDataStore,
|
||||||
'Version', TVpAboutProperty);
|
'Version', TVpAboutProperty);
|
||||||
@ -452,27 +453,27 @@ begin
|
|||||||
RegisterPropertyEditor(TypeInfo(string), TVpPrintFormatComboBox,
|
RegisterPropertyEditor(TypeInfo(string), TVpPrintFormatComboBox,
|
||||||
'Version', TVpAboutProperty);
|
'Version', TVpAboutProperty);
|
||||||
|
|
||||||
{register the BDE Alias and Driver properties }
|
|
||||||
{$IFDEF DELPHI}
|
{$IFDEF DELPHI}
|
||||||
|
{register the BDE Alias and Driver properties }
|
||||||
|
|
||||||
RegisterPropertyEditor(TypeInfo(string), TVpBDEDataStore,
|
RegisterPropertyEditor(TypeInfo(string), TVpBDEDataStore,
|
||||||
'AliasName', TAliasNameProperty);
|
'AliasName', TAliasNameProperty);
|
||||||
RegisterPropertyEditor(TypeInfo(string), TVpBDEDataStore,
|
RegisterPropertyEditor(TypeInfo(string), TVpBDEDataStore,
|
||||||
'DriverName', TDriverNameProperty);
|
'DriverName', TDriverNameProperty);
|
||||||
{$ENDIF}
|
|
||||||
|
{register the DayView properties }
|
||||||
|
|
||||||
// LCL: Registering next property editor inhibits that the DataStore
|
// LCL: Registering next property editor inhibits that the DataStore
|
||||||
// property combo of the DayView lists the available datastores.
|
// property combo of the DayView lists the available datastores.
|
||||||
|
RegisterPropertyEditor(TypeInfo(TVpCustomDataStore), TVpDayView,
|
||||||
{register the DayView properties }
|
'DataStore', TDataStoreProperty);
|
||||||
//RegisterPropertyEditor(TypeInfo(TVpCustomDataStore), TVpDayView,
|
|
||||||
// 'DataStore', TDataStoreProperty);
|
|
||||||
|
|
||||||
{register the property editor for the DataStore's DefaultAlarmWav }
|
{register the property editor for the DataStore's DefaultAlarmWav }
|
||||||
{ NO - not useful in design mode because there is not platform-independent way
|
// NO - not useful in design mode because there is not platform-independent way
|
||||||
to play the sound
|
// to play the sound }
|
||||||
RegisterPropertyEditor(TypeInfo(string), TVpCustomDataStore,
|
RegisterPropertyEditor(TypeInfo(string), TVpCustomDataStore,
|
||||||
'DefaultEventSound', TWavFileProperty);
|
'DefaultEventSound', TWavFileProperty);
|
||||||
}
|
{$ENDIF}
|
||||||
|
|
||||||
RegisterPropertyEditor(TypeInfo(String), TVpCustomDatastore,
|
RegisterPropertyEditor(TypeInfo(String), TVpCustomDatastore,
|
||||||
'DefaultEventSound', TVpWavFileProperty);
|
'DefaultEventSound', TVpWavFileProperty);
|
||||||
@ -495,7 +496,10 @@ begin
|
|||||||
RegisterPropertyEditor(TypeInfo(string), TVpControlLink,
|
RegisterPropertyEditor(TypeInfo(string), TVpControlLink,
|
||||||
'LocalizationFile', TVpLocalizeFileNameProperty);
|
'LocalizationFile', TVpLocalizeFileNameProperty);
|
||||||
|
|
||||||
|
|
||||||
|
{----------------------------------------------------------------------------}
|
||||||
{ register Visual PlanIt components with the IDE }
|
{ register Visual PlanIt components with the IDE }
|
||||||
|
{----------------------------------------------------------------------------}
|
||||||
RegisterComponents('Visual PlanIt', [
|
RegisterComponents('Visual PlanIt', [
|
||||||
TVpLEDLabel,
|
TVpLEDLabel,
|
||||||
TVpClock,
|
TVpClock,
|
||||||
|
Reference in New Issue
Block a user