jvcllaz: Add missing properties to the JvXXXXViewer components (issue #0034104, patch by Michal Gawrycki)

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@6608 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2018-08-17 19:23:49 +00:00
parent f8f096dcf8
commit e3e882ce59
4 changed files with 42 additions and 12 deletions

View File

@ -203,7 +203,7 @@ type
FOnDrawItem: TJvViewerItemDrawEvent; FOnDrawItem: TJvViewerItemDrawEvent;
FDragImages: TDragImageList; FDragImages: TDragImageList;
FUpdateCount, FCols, FRows, FTempSelected, FSelectedIndex, FLastHotTrack: Integer; FUpdateCount, FCols, FRows, FTempSelected, FSelectedIndex, FLastHotTrack: Integer;
FBorderStyle: TBorderStyle; //FBorderStyle: TBorderStyle;
FTopLeftIndex: Integer; FTopLeftIndex: Integer;
FBottomRightIndex: Integer; FBottomRightIndex: Integer;
FOnScroll: TNotifyEvent; FOnScroll: TNotifyEvent;
@ -296,7 +296,7 @@ type
property BottomRightIndex: Integer read FBottomRightIndex; property BottomRightIndex: Integer read FBottomRightIndex;
property UpdateCount: Integer read FUpdateCount; property UpdateCount: Integer read FUpdateCount;
property BorderStyle: TBorderStyle read FBorderStyle write SetBorderStyle default bsSingle; //property BorderStyle: TBorderStyle read FBorderStyle write SetBorderStyle default bsSingle;
property ParentColor default False; property ParentColor default False;
property SelectedIndex: Integer read FSelectedIndex write SetSelectedIndex; property SelectedIndex: Integer read FSelectedIndex write SetSelectedIndex;
property Selected[Item: TJvViewerItem]: Boolean read GetSelected write SetSelected; property Selected[Item: TJvViewerItem]: Boolean read GetSelected write SetSelected;
@ -329,6 +329,7 @@ type
procedure Delete(Index: Integer); procedure Delete(Index: Integer);
function IndexOf(Item: TJvViewerItem): Integer; function IndexOf(Item: TJvViewerItem): Integer;
function ItemAtPos(X, Y: Integer; Existing: Boolean): Integer; virtual; function ItemAtPos(X, Y: Integer; Existing: Boolean): Integer; virtual;
property BorderStyle default bsSingle;
end; end;
// Creates a 8x8 brush pattern with alternate odd and even colors // Creates a 8x8 brush pattern with alternate odd and even colors
@ -823,7 +824,7 @@ begin
VertScrollBar.Smooth := Options.Smooth; VertScrollBar.Smooth := Options.Smooth;
VertScrollBar.Tracking := Options.Tracking; VertScrollBar.Tracking := Options.Tracking;
DoubleBuffered := True; DoubleBuffered := True;
FBorderStyle := bsSingle; BorderStyle := bsSingle;
Width := 185; Width := 185;
Height := 150; Height := 150;
TabStop := True; TabStop := True;
@ -965,15 +966,15 @@ const
BorderStyles: array [TBorderStyle] of DWORD = (0, WS_BORDER); BorderStyles: array [TBorderStyle] of DWORD = (0, WS_BORDER);
begin begin
inherited CreateParams(Params); inherited CreateParams(Params);
with Params do //with Params do
begin //begin
Style := Style or BorderStyles[BorderStyle]; // Style := Style or BorderStyles[BorderStyle];
//if Ctl3D and (BorderStyle = bsSingle) then // //if Ctl3D and (BorderStyle = bsSingle) then
//begin // //begin
// Style := Style and not WS_BORDER; // // Style := Style and not WS_BORDER;
// ExStyle := ExStyle or WS_EX_CLIENTEDGE; // // ExStyle := ExStyle or WS_EX_CLIENTEDGE;
//end; // //end;
end; //end;
with Params.WindowClass do with Params.WindowClass do
Style := Style or (CS_HREDRAW or CS_VREDRAW); { or CS_SAVEBITS} Style := Style or (CS_HREDRAW or CS_VREDRAW); { or CS_SAVEBITS}
end; end;

View File

@ -91,6 +91,8 @@ type
property Anchors; property Anchors;
// property BiDiMode; // property BiDiMode;
property BorderSpacing; property BorderSpacing;
property BorderStyle;
property BorderWidth;
property Color; property Color;
property Constraints; property Constraints;
property DockSite; property DockSite;
@ -129,12 +131,19 @@ type
property OnMouseDown; property OnMouseDown;
property OnMouseMove; property OnMouseMove;
property OnMouseUp; property OnMouseUp;
property OnMouseEnter;
property OnMouseLeave;
property OnMouseWheel;
property OnMouseWheelDown;
property OnMouseWheelUp;
property OnKeyDown; property OnKeyDown;
property OnKeyUp; property OnKeyUp;
property OnKeyPress; property OnKeyPress;
property OnResize;
property OnStartDock; property OnStartDock;
property OnStartDrag; property OnStartDrag;
property OnUnDock; property OnUnDock;
property OnUTF8KeyPress;
end; end;
implementation implementation

View File

@ -160,6 +160,8 @@ type
property Anchors; property Anchors;
// property BiDiMode; // property BiDiMode;
property BorderSpacing; property BorderSpacing;
property BorderStyle;
property BorderWidth;
property Color; property Color;
property Constraints; property Constraints;
property DockSite; property DockSite;
@ -194,10 +196,17 @@ type
property OnMouseDown; property OnMouseDown;
property OnMouseMove; property OnMouseMove;
property OnMouseUp; property OnMouseUp;
property OnMouseEnter;
property OnMouseLeave;
property OnMouseWheel;
property OnMouseWheelDown;
property OnMouseWheelUp;
property OnKeyDown; property OnKeyDown;
property OnKeyUp; property OnKeyUp;
property OnKeyPress; property OnKeyPress;
property OnResize;
property OnStartDrag; property OnStartDrag;
property OnUTF8KeyPress;
end; end;
implementation implementation

View File

@ -71,11 +71,15 @@ type
property OnItemChanging; property OnItemChanging;
property OnItemChanged; property OnItemChanged;
property OnItemHint; property OnItemHint;
property OnDeletion;
property OnInsertion;
property Align; property Align;
property Anchors; property Anchors;
// property BiDiMode; // property BiDiMode;
property BorderSpacing; property BorderSpacing;
property BorderStyle;
property BorderWidth;
property Color; property Color;
property Constraints; property Constraints;
property DockSite; property DockSite;
@ -108,12 +112,19 @@ type
property OnMouseDown; property OnMouseDown;
property OnMouseMove; property OnMouseMove;
property OnMouseUp; property OnMouseUp;
property OnMouseEnter;
property OnMouseLeave;
property OnMouseWheel;
property OnMouseWheelDown;
property OnMouseWheelUp;
property OnKeyDown; property OnKeyDown;
property OnKeyUp; property OnKeyUp;
property OnKeyPress; property OnKeyPress;
property OnResize;
property OnStartDock; property OnStartDock;
property OnStartDrag; property OnStartDrag;
property OnUnDock; property OnUnDock;
property OnUTF8KeyPress;
end; end;
implementation implementation