You've already forked lazarus-ccr
tvplanit: Rename internal monthviewpainter variable.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8539 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -12,11 +12,11 @@ type
|
|||||||
TVpMonthViewPainter = class(TVpBasePainter)
|
TVpMonthViewPainter = class(TVpBasePainter)
|
||||||
private
|
private
|
||||||
FMonthView: TVpMonthView;
|
FMonthView: TVpMonthView;
|
||||||
|
FDisplayDate: TDateTime;
|
||||||
FScaledMonthMargin: Integer;
|
FScaledMonthMargin: Integer;
|
||||||
FScaledDaysMargin: Integer;
|
FScaledDaysMargin: Integer;
|
||||||
|
|
||||||
// local parameters of the old TVpMonthView method
|
// local parameters of the old TVpMonthView method
|
||||||
DisplayDate: TDateTime;
|
|
||||||
DisplayMonth: Word;
|
DisplayMonth: Word;
|
||||||
RealColor: TColor;
|
RealColor: TColor;
|
||||||
BevelHighlight: TColor;
|
BevelHighlight: TColor;
|
||||||
@ -167,7 +167,7 @@ begin
|
|||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
fontstyle := RenderCanvas.Font.style;
|
fontstyle := RenderCanvas.Font.style;
|
||||||
|
|
||||||
if (DisplayDate = ADate) then begin
|
if (FDisplayDate = ADate) then begin
|
||||||
if FMonthView.Focused then begin
|
if FMonthView.Focused then begin
|
||||||
if ACol = 6 then begin
|
if ACol = 6 then begin
|
||||||
tmpRect := ATextRect;
|
tmpRect := ATextRect;
|
||||||
@ -418,7 +418,7 @@ begin
|
|||||||
TextRect.BottomRight := Point(TextRect.Left + mvColWidth, TextRect.Top + mvRowHeight);
|
TextRect.BottomRight := Point(TextRect.Left + mvColWidth, TextRect.Top + mvRowHeight);
|
||||||
|
|
||||||
// Determine the starting date and offset
|
// Determine the starting date and offset
|
||||||
DecodeDate(DisplayDate, Y, DisplayMonth, D);
|
DecodeDate(FDisplayDate, Y, DisplayMonth, D);
|
||||||
StartingDate := EncodeDate(Y, DisplayMonth, 1);
|
StartingDate := EncodeDate(Y, DisplayMonth, 1);
|
||||||
MonthStartsOn := DayOfWeek(StartingDate);
|
MonthStartsOn := DayOfWeek(StartingDate);
|
||||||
DayTag := Ord(FMonthView.WeekStartsOn);
|
DayTag := Ord(FMonthView.WeekStartsOn);
|
||||||
@ -675,7 +675,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
{ Acquire startdate and end date }
|
{ Acquire startdate and end date }
|
||||||
HeadStr := FormatDateTime(FMonthView.DateLabelFormat, DisplayDate);
|
HeadStr := FormatDateTime(FMonthView.DateLabelFormat, FDisplayDate);
|
||||||
{$IFDEF FPC}{$IF FPC_FULLVERSION < 30000}
|
{$IFDEF FPC}{$IF FPC_FULLVERSION < 30000}
|
||||||
HeadStr := SysToUTF8(HeadStr);
|
HeadStr := SysToUTF8(HeadStr);
|
||||||
{$ENDIF}{$ENDIF}
|
{$ENDIF}{$ENDIF}
|
||||||
@ -832,13 +832,13 @@ end;
|
|||||||
|
|
||||||
procedure TVpMonthViewPainter.SetMeasurements;
|
procedure TVpMonthViewPainter.SetMeasurements;
|
||||||
var
|
var
|
||||||
h, scaledMargin: Integer;
|
h: Integer;
|
||||||
txt: String = VpProductName;
|
txt: String = VpProductName;
|
||||||
// We use the VpProductName since it is a good representation of some generic text
|
// We use the VpProductName since it is a good representation of some generic text
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
|
|
||||||
DisplayDate := IfThen(RenderDate = 0, Date, RenderDate);
|
FDisplayDate := IfThen(RenderDate = 0, Date, RenderDate);
|
||||||
|
|
||||||
with TVpMonthViewOpener(FMonthView) do
|
with TVpMonthViewOpener(FMonthView) do
|
||||||
begin
|
begin
|
||||||
|
Reference in New Issue
Block a user