diff --git a/components/callite/README.txt b/components/callite/README.txt
new file mode 100644
index 000000000..72eb305c1
--- /dev/null
+++ b/components/callite/README.txt
@@ -0,0 +1,6 @@
+TCalendarLite is a light-weight calendar component, a TGraphicControl
+descendant which consequently is not dependent on any widgetset.
+It is not a fixed-size component, as are most calendars, but will align
+and resize as needed.
+
+License: modified LGPL (with linking exception)
\ No newline at end of file
diff --git a/components/callite/demo1/CalLiteTest.lpi b/components/callite/demo1/CalLiteTest.lpi
index a6fdadfda..f990be5eb 100644
--- a/components/callite/demo1/CalLiteTest.lpi
+++ b/components/callite/demo1/CalLiteTest.lpi
@@ -9,7 +9,6 @@
-
@@ -58,6 +57,7 @@
+
diff --git a/components/callite/demo1/main.lfm b/components/callite/demo1/main.lfm
index 0191474dc..a82129c6b 100644
--- a/components/callite/demo1/main.lfm
+++ b/components/callite/demo1/main.lfm
@@ -12,7 +12,7 @@ object Form1: TForm1
OnCreate = FormCreate
OnResize = FormResize
Position = poScreenCenter
- LCLVersion = '1.7'
+ LCLVersion = '1.6.0.4'
object edtYear: TEdit
Left = 122
Height = 18
diff --git a/components/callite/demo1/main.pas b/components/callite/demo1/main.pas
index 61e9af0e2..ad23a421f 100644
--- a/components/callite/demo1/main.pas
+++ b/components/callite/demo1/main.pas
@@ -6,7 +6,7 @@ interface
uses
Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ExtCtrls,
- LclType, Buttons, StdCtrls, ComCtrls, Grids, DateUtils, CalendarLite;
+ LclType, Buttons, StdCtrls, DateUtils, CalendarLite;
type
@@ -17,8 +17,8 @@ type
edtMonth: TEdit;
Label1: TLabel;
procedure btnCloseClick(Sender: TObject);
- procedure edtYearKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
- procedure edtMonthKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
+ procedure edtYearKeyDown(Sender: TObject; var Key: Word; {%H-}Shift: TShiftState);
+ procedure edtMonthKeyDown(Sender: TObject; var Key: Word; {%H-}Shift: TShiftState);
procedure FormCreate(Sender: TObject);
procedure FormResize(Sender: TObject);
private
@@ -64,7 +64,7 @@ begin
MonthsList:= TStringList.Create;
for I:= 0 to 11 do begin
- MonthsList.Add(AnsiToUTF8(ShortMonthNames[I+1]));
+ MonthsList.Add(AnsiToUTF8(FormatSettings.ShortMonthNames[I+1]));
end;
AYear:= YearOf(Now);
diff --git a/components/callite/source/calendarlite.pas b/components/callite/source/calendarlite.pas
index df4a14f2e..b36bec9f6 100644
--- a/components/callite/source/calendarlite.pas
+++ b/components/callite/source/calendarlite.pas
@@ -302,10 +302,15 @@ end;
procedure TCalDrawer.CalcSettings;
var
- rem, i, cellWidths, totalSpace, cw, cellHeights, hSpc,
- adjSpace, sp, borderh, borderv, ch, numRows: integer;
- sz: TSize;
+ rem: Integer = 0;
+ hSpc: Integer = 0;
+ ch: Integer = 0;
+ sp: Integer = 0;
+ cw: Integer = 0;
bit: integer=0;
+ i, cellWidths, totalSpace, cellHeights,
+ adjSpace, borderh, borderv, numRows: integer;
+ sz: TSize;
begin
if (FOwner.BiDiMode = bdLeftToRight) then
FTStyle.RightToLeft:= False
@@ -448,13 +453,15 @@ end;
procedure TCalDrawer.DrawDayCells;
var
- r, c, startCol, startRow, startSpan: integer;
+ remDays: integer = 0;
+ startRow: Integer = 0;
+ holidays: THolidays = 0;
+ r, c, startCol, startSpan: integer;
rec: TRect;
s: string;
dow, y, m, d: word;
- partWeeks, remDays: integer;
+ partWeeks: Integer;
dt, todayDate: TDateTime;
- holidays: THolidays;
begin
todayDate := Date;
dow := DayOfWeek(FOwner.FDate);
@@ -850,7 +857,7 @@ begin
2: PrevMonth;
3..5:
begin
- GetMonthYearRects(Rm, Ry);
+ GetMonthYearRects(Rm{%H-}, Ry{%H-});
if PtInRect(Rm, p) then begin
FOwner.PopulateMonthPopupMenu;
ppopup := FOwner.ClientToScreen(Point(Rm.Left, Rm.Bottom));
@@ -1097,7 +1104,7 @@ var
item: TMenuItem;
m, d, dayCount: Integer;
population: integer = 0;
- hols: THolidays;
+ hols: THolidays = 0;
dt: TDateTime;
begin
with FPopupMenu.Items do begin