You've already forked lazarus-ccr
RxDBGrid - remove depricated property AllowedOperations
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@2836 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -54,9 +54,11 @@
|
|||||||
|
|
||||||
{$if FPC_FULLVERSION<20701}
|
{$if FPC_FULLVERSION<20701}
|
||||||
{$DEFINE NoAutomatedBookmark}
|
{$DEFINE NoAutomatedBookmark}
|
||||||
|
{$DEFINE RX_USE_LCL_DEVEL}
|
||||||
{$endif}
|
{$endif}
|
||||||
|
|
||||||
{$IFDEF NoAutomatedBookmark}
|
{$IFDEF NoAutomatedBookmark}
|
||||||
{$ELSE}
|
{$ELSE}
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
|
|
||||||
|
{.$DEFINE RxDBGridDepricatedProps}
|
||||||
|
@ -40,9 +40,7 @@ uses
|
|||||||
Graphics, Dialogs, Grids, dbutils, DBGrids, DB, PropertyStorage, vclutils,
|
Graphics, Dialogs, Grids, dbutils, DBGrids, DB, PropertyStorage, vclutils,
|
||||||
LMessages, types, StdCtrls, Menus;
|
LMessages, types, StdCtrls, Menus;
|
||||||
|
|
||||||
{$if ((lcl_major = 1) and (lcl_minor = 1))}
|
{//$if ((lcl_major = 1) and (lcl_minor = 1))}
|
||||||
{$DEFINE RX_USE_LCL_DEVEL}
|
|
||||||
{$ENDIF}
|
|
||||||
|
|
||||||
const
|
const
|
||||||
CBadQuickSearchSymbols = [VK_UNKNOWN..VK_HELP] + [VK_LWIN..VK_SLEEP] +
|
CBadQuickSearchSymbols = [VK_UNKNOWN..VK_HELP] + [VK_LWIN..VK_SLEEP] +
|
||||||
@ -70,8 +68,10 @@ type
|
|||||||
TGetCellPropsEvent = procedure(Sender: TObject; Field: TField;
|
TGetCellPropsEvent = procedure(Sender: TObject; Field: TField;
|
||||||
AFont: TFont; var Background: TColor) of object;
|
AFont: TFont; var Background: TColor) of object;
|
||||||
|
|
||||||
TRxDBGridAllowedOperation = (aoInsert, aoUpdate, aoDelete, aoAppend);
|
{$IFDEF RxDBGridDepricatedProps}
|
||||||
TRxDBGridAllowedOperations = set of TRxDBGridAllowedOperation;
|
//TRxDBGridAllowedOperation = (aoInsert, aoUpdate, aoDelete, aoAppend);
|
||||||
|
//TRxDBGridAllowedOperations = set of TRxDBGridAllowedOperation;
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
TRxColumnEditButtonStyle = (ebsDropDownRx, ebsEllipsisRx, ebsGlyphRx, ebsUpDownRx,
|
TRxColumnEditButtonStyle = (ebsDropDownRx, ebsEllipsisRx, ebsGlyphRx, ebsUpDownRx,
|
||||||
ebsPlusRx, ebsMinusRx);
|
ebsPlusRx, ebsMinusRx);
|
||||||
@ -523,7 +523,7 @@ type
|
|||||||
FOldDataSetState:TDataSetState;
|
FOldDataSetState:TDataSetState;
|
||||||
|
|
||||||
procedure DoCreateJMenu;
|
procedure DoCreateJMenu;
|
||||||
function GetAllowedOperations: TRxDBGridAllowedOperations;
|
//function GetAllowedOperations: TRxDBGridAllowedOperations;
|
||||||
function GetColumns: TRxDbGridColumns;
|
function GetColumns: TRxDbGridColumns;
|
||||||
function GetFooterColor: TColor;
|
function GetFooterColor: TColor;
|
||||||
function GetFooterRowCount: integer;
|
function GetFooterRowCount: integer;
|
||||||
@ -534,7 +534,10 @@ type
|
|||||||
function GetSortOrder: TSortMarker;
|
function GetSortOrder: TSortMarker;
|
||||||
function GetTitleButtons: boolean;
|
function GetTitleButtons: boolean;
|
||||||
function IsColumnsStored: boolean;
|
function IsColumnsStored: boolean;
|
||||||
|
|
||||||
|
{$IFDEF RxDBGridDepricatedProps}
|
||||||
procedure SetAllowedOperations(AValue: TRxDBGridAllowedOperations);
|
procedure SetAllowedOperations(AValue: TRxDBGridAllowedOperations);
|
||||||
|
{$ENDIF}
|
||||||
procedure SetAutoSort(const AValue: boolean);
|
procedure SetAutoSort(const AValue: boolean);
|
||||||
procedure SetColumns(const AValue: TRxDbGridColumns);
|
procedure SetColumns(const AValue: TRxDbGridColumns);
|
||||||
procedure SetFooterColor(const AValue: TColor);
|
procedure SetFooterColor(const AValue: TColor);
|
||||||
@ -713,8 +716,10 @@ type
|
|||||||
property PropertyStorage: TCustomPropertyStorage
|
property PropertyStorage: TCustomPropertyStorage
|
||||||
read GetPropertyStorage write SetPropertyStorage;
|
read GetPropertyStorage write SetPropertyStorage;
|
||||||
property Version: integer read FVersion write FVersion default 0;
|
property Version: integer read FVersion write FVersion default 0;
|
||||||
|
{$IFDEF RxDBGridDepricatedProps}
|
||||||
property AllowedOperations: TRxDBGridAllowedOperations
|
property AllowedOperations: TRxDBGridAllowedOperations
|
||||||
read GetAllowedOperations write SetAllowedOperations default [aoInsert, aoUpdate, aoDelete, aoAppend]; deprecated;
|
read GetAllowedOperations write SetAllowedOperations default [aoInsert, aoUpdate, aoDelete, aoAppend]; deprecated;
|
||||||
|
{$ENDIF}
|
||||||
property OptionsRx: TOptionsRx read FOptionsRx write SetOptionsRx;
|
property OptionsRx: TOptionsRx read FOptionsRx write SetOptionsRx;
|
||||||
property FooterColor: TColor read GetFooterColor write SetFooterColor default clWindow; deprecated;
|
property FooterColor: TColor read GetFooterColor write SetFooterColor default clWindow; deprecated;
|
||||||
property FooterRowCount: integer read GetFooterRowCount write SetFooterRowCount default 0; deprecated;
|
property FooterRowCount: integer read GetFooterRowCount write SetFooterRowCount default 0; deprecated;
|
||||||
@ -1697,6 +1702,7 @@ begin
|
|||||||
CreateMenuItem('A', sRxDBGridSelectAllRows, @OnSelectAllRows);
|
CreateMenuItem('A', sRxDBGridSelectAllRows, @OnSelectAllRows);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
{$IFDEF RxDBGridDepricatedProps}
|
||||||
function TRxDBGrid.GetAllowedOperations: TRxDBGridAllowedOperations;
|
function TRxDBGrid.GetAllowedOperations: TRxDBGridAllowedOperations;
|
||||||
begin
|
begin
|
||||||
Result:=[];
|
Result:=[];
|
||||||
@ -1712,6 +1718,7 @@ begin
|
|||||||
Result:=Result + [aoDelete]
|
Result:=Result + [aoDelete]
|
||||||
;
|
;
|
||||||
end;
|
end;
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
function TRxDBGrid.GetPropertyStorage: TCustomPropertyStorage;
|
function TRxDBGrid.GetPropertyStorage: TCustomPropertyStorage;
|
||||||
begin
|
begin
|
||||||
@ -1744,6 +1751,7 @@ begin
|
|||||||
Result := TRxDbGridColumns(TCustomDrawGrid(Self).Columns).Enabled;
|
Result := TRxDbGridColumns(TCustomDrawGrid(Self).Columns).Enabled;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
{$IFDEF RxDBGridDepricatedProps}
|
||||||
procedure TRxDBGrid.SetAllowedOperations(AValue: TRxDBGridAllowedOperations);
|
procedure TRxDBGrid.SetAllowedOperations(AValue: TRxDBGridAllowedOperations);
|
||||||
begin
|
begin
|
||||||
// FAllowedOperations:=AValue;
|
// FAllowedOperations:=AValue;
|
||||||
@ -1757,6 +1765,7 @@ begin
|
|||||||
else
|
else
|
||||||
Options:=Options + [dgDisableDelete]
|
Options:=Options + [dgDisableDelete]
|
||||||
end;
|
end;
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
procedure TRxDBGrid.SetColumns(const AValue: TRxDbGridColumns);
|
procedure TRxDBGrid.SetColumns(const AValue: TRxDbGridColumns);
|
||||||
begin
|
begin
|
||||||
@ -5442,6 +5451,9 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
initialization
|
initialization
|
||||||
|
{$IFNDEF RxDBGridDepricatedProps}
|
||||||
|
RegisterPropertyToSkip( TRxDBGrid, 'AllowedOperations', 'This property duplicated standart DBGrid.Options', '');
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
{$I rxdbgrid.lrs}
|
{$I rxdbgrid.lrs}
|
||||||
// {$I rx_markerdown.lrs}
|
// {$I rx_markerdown.lrs}
|
||||||
|
Reference in New Issue
Block a user