diff --git a/components/nicegrid/demos/Basic Demo/Project_Lazarus/basic_demo.lpi b/components/nicegrid/demos/Basic Demo/Project_Lazarus/basic_demo.lpi index 820f93c98..dfd5e14e8 100644 --- a/components/nicegrid/demos/Basic Demo/Project_Lazarus/basic_demo.lpi +++ b/components/nicegrid/demos/Basic Demo/Project_Lazarus/basic_demo.lpi @@ -42,7 +42,7 @@ - + @@ -69,7 +69,7 @@ - + @@ -101,9 +101,9 @@ - - - + + + @@ -112,9 +112,9 @@ - - - + + + @@ -122,7 +122,7 @@ - + @@ -130,7 +130,7 @@ - + @@ -139,7 +139,7 @@ - + @@ -148,7 +148,7 @@ - + @@ -157,130 +157,130 @@ - + - + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - + - + - + - - + + - - + + - + - + - + - + - + - + - + - + - + - + - - + + diff --git a/components/nicegrid/source/nicegrid.pas b/components/nicegrid/source/nicegrid.pas index 945876bd9..93460be54 100644 --- a/components/nicegrid/source/nicegrid.pas +++ b/components/nicegrid/source/nicegrid.pas @@ -554,7 +554,7 @@ const CursorArray: array [TGridHitTest] of TCursor = //(gtNone, gtLeftTop, gtLeft, gtTop, gtCell, gtColSizing, gtSmallBox); - {$IFDEF LCLGtk3} + {$IFDEF LCLGtk3} // Issue with loading cursors in GTK3 --> use predefined cursors. (crDefault, crSizeSE, crSizeE, crSizeS, crHandPoint, crHSplit, crCross); {$ELSE} (crDefault, crLeftTop, crRight, crDown, crPlus, crHSplit, crSmallCross); @@ -565,6 +565,15 @@ const MergeID = -2; +{$HINTS OFF} +procedure Unused(const A1); overload; +begin +end; + +procedure Unused(const A1, A2); overload; +begin +end; +{$HINTS ON} { TNiceGrid } @@ -638,13 +647,8 @@ begin SmallBoxPos := 0; SizingCol := -1; SizingColX := -1; - {$IFDEF LCLGtk3} - Screen.Cursors[crPlus] := Screen.Cursors[crHandPoint]; - Screen.Cursors[crSmallCross] := Screen.Cursors[crCross]; - Screen.Cursors[crRight] := Screen.Cursors[crSizeE]; - Screen.Cursors[crDown] := Screen.Cursors[crSizeS]; - Screen.Cursors[crLeftTop] := Screen.Cursors[crSizeSE]; - {$ELSE} + + {$IFNDEF LCLGtk3} // Issue with loading cursors in GTK3. Screen.Cursors[crPlus] := LoadCursor(hinstance, 'CR_PLUS'); Screen.Cursors[crSmallCross] := LoadCursor(hInstance, 'CR_CROSS'); Screen.Cursors[crRight] := LoadCursor(hinstance, 'CR_RIGHT'); @@ -3172,6 +3176,7 @@ end; procedure TNiceGrid.WMSetFocus(var Msg: {$IFDEF FPC}TLMSetFocus{$ELSE}TWMSetFocus{$ENDIF}); begin + Unused(Msg); CreateCaret(Handle, 0, 1, FDefRowHeight - 2); CaretVisible := False; InvalidateCells; @@ -4176,6 +4181,7 @@ end; procedure TNiceGridSync.SetScrollBar(AKind, AMax, APos, AMask: Integer); begin + Unused(AMax); if (AKind = SB_VERT) and Assigned(FGrid) then begin if ((AMask and SIF_POS) <> 0) @@ -4186,6 +4192,7 @@ end; procedure TNiceGridSync.ShowHideScrollBar(HorzVisible, VertVisible: Boolean); begin + Unused(HorzVisible, VertVisible); ShowScrollBar(Handle, SB_HORZ, True); ShowScrollBar(Handle, SB_VERT, False); EnableScrollBar(Handle, SB_HORZ, 3{ESB_DISABLE_BOTH}); @@ -4193,6 +4200,7 @@ end; procedure TNiceGridSync.SyncColRow(Sender: TObject; ACol, ARow: Integer); begin + Unused(ACol); if Assigned(FGrid) then FGrid.Row := ARow; end;