mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-17 20:59:12 +02:00
ideintf: introduce new method TObjectInspectorDlg.FocusGrid
git-svn-id: trunk@21810 -
This commit is contained in:
parent
5507b410fc
commit
6369c296cc
@ -703,6 +703,7 @@ type
|
|||||||
function GetActivePropertyRow: TOIPropertyGridRow;
|
function GetActivePropertyRow: TOIPropertyGridRow;
|
||||||
function GetCurRowDefaultValue(var DefaultStr: string): boolean;
|
function GetCurRowDefaultValue(var DefaultStr: string): boolean;
|
||||||
procedure HookRefreshPropertyValues;
|
procedure HookRefreshPropertyValues;
|
||||||
|
procedure FocusGrid;
|
||||||
|
|
||||||
property AutoShow: Boolean read FAutoShow write FAutoShow;
|
property AutoShow: Boolean read FAutoShow write FAutoShow;
|
||||||
property DefaultItemHeight: integer read FDefaultItemHeight
|
property DefaultItemHeight: integer read FDefaultItemHeight
|
||||||
@ -4855,6 +4856,21 @@ begin
|
|||||||
RefreshPropertyValues;
|
RefreshPropertyValues;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TObjectInspectorDlg.FocusGrid;
|
||||||
|
var
|
||||||
|
Grid: TOICustomPropertyGrid;
|
||||||
|
Index: Integer;
|
||||||
|
begin
|
||||||
|
Grid := GetActivePropertyGrid;
|
||||||
|
if Grid <> nil then
|
||||||
|
begin
|
||||||
|
Index := Grid.ItemIndex;
|
||||||
|
if Index < 0 then
|
||||||
|
Index := 0;
|
||||||
|
Grid.SetItemIndexAndFocus(Index);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
function TObjectInspectorDlg.GetGridControl(Page: TObjectInspectorPage
|
function TObjectInspectorDlg.GetGridControl(Page: TObjectInspectorPage
|
||||||
): TOICustomPropertyGrid;
|
): TOICustomPropertyGrid;
|
||||||
begin
|
begin
|
||||||
|
Loading…
Reference in New Issue
Block a user