jvcllaz: Activate mousewheel support for appointments displayed within day cells of JvTFWeeks and JvTFMonths .

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7115 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2019-08-10 16:15:15 +00:00
parent 23a82fa5b8
commit 93c3a3bf73
3 changed files with 29 additions and 6 deletions

View File

@ -1490,8 +1490,6 @@ begin
end;
end;
function TJvTFCustomGlance.DateIsSelected(ADate: TDate): Boolean;
begin
Result := Sel.IndexOf(ADate) <> -1;

View File

@ -121,6 +121,10 @@ type
procedure DragOver(Source: TObject; X, Y: Integer; State: TDragState;
var Accept: Boolean); override;
// mouse wheel support
function DoMouseWheelDown(Shift: TShiftState; MousePos: TPoint): Boolean; override ;
function DoMouseWheelUp(Shift: TShiftState; MousePos: TPoint): Boolean; override;
property Replicating: Boolean read FReplicating;
procedure Paint; override;
procedure DrawDDButton(ACanvas: TCanvas);
@ -737,6 +741,25 @@ begin
Result := Rel - TopLine;
end;
function TJvTFGVTextControl.DoMouseWheelDown(Shift: TShiftState;
MousePos: TPoint): Boolean;
begin
Result := inherited;
if not Result then begin
Scroll(+1);
Result := true;
end;
end;
function TJvTFGVTextControl.DoMouseWheelUp(Shift: TShiftState;
MousePos: TPoint): Boolean;
begin
Result := inherited;
if not Result then begin
Scroll(-1);
end;
end;
procedure TJvTFGVTextControl.DoViewerDblClick;
begin
if FHasScrolled then