From: <ob...@us...> - 2009-04-10 20:08:17
|
Revision: 12264 http://jvcl.svn.sourceforge.net/jvcl/?rev=12264&view=rev Author: obones Date: 2009-04-10 20:08:13 +0000 (Fri, 10 Apr 2009) Log Message: ----------- D5/C5 compatibility issues. Modified Paths: -------------- trunk/jvcl/run/JvDockControlForm.pas trunk/jvcl/run/JvDockTree.pas trunk/jvcl/run/JvListView.pas trunk/jvcl/run/JvTMTimeLine.pas trunk/jvcl/run/JvVCL5Utils.pas trunk/jvcl/run/JvgXMLSerializer.pas Modified: trunk/jvcl/run/JvDockControlForm.pas =================================================================== --- trunk/jvcl/run/JvDockControlForm.pas 2009-04-01 23:17:57 UTC (rev 12263) +++ trunk/jvcl/run/JvDockControlForm.pas 2009-04-10 20:08:13 UTC (rev 12264) @@ -894,7 +894,7 @@ {$ELSE} IniFiles, Registry, {$ENDIF USEJVCL} - JvDockSupportProc, JvDockGlobals, JvDockInfo, JvDockVSNetStyle; + JvDockSupportProc, JvDockGlobals, JvDockInfo, JvDockVSNetStyle, JvVCL5Utils; {$R JvDockableForm.dfm} {$R JvDockConjoinHost.dfm} Modified: trunk/jvcl/run/JvDockTree.pas =================================================================== --- trunk/jvcl/run/JvDockTree.pas 2009-04-01 23:17:57 UTC (rev 12263) +++ trunk/jvcl/run/JvDockTree.pas 2009-04-10 20:08:13 UTC (rev 12264) @@ -616,7 +616,7 @@ {$ENDIF JVCLThemesEnabled} Consts, SysUtils, Math, JvDockControlForm, JvDockSupportProc, JvDockGlobals, JvDockVSNetStyle, - JvDockAdvTree; + JvDockAdvTree, JvVCL5Utils; type TWinControlAccessProtected = class(TWinControl); Modified: trunk/jvcl/run/JvListView.pas =================================================================== --- trunk/jvcl/run/JvListView.pas 2009-04-01 23:17:57 UTC (rev 12263) +++ trunk/jvcl/run/JvListView.pas 2009-04-10 20:08:13 UTC (rev 12264) @@ -502,7 +502,7 @@ {$ELSE} ActiveX, {$ENDIF HAS_UNIT_VARIANTS} - JclWideStrings, + JclWideStrings, JvConsts, JvResources; type Modified: trunk/jvcl/run/JvTMTimeLine.pas =================================================================== --- trunk/jvcl/run/JvTMTimeLine.pas 2009-04-01 23:17:57 UTC (rev 12263) +++ trunk/jvcl/run/JvTMTimeLine.pas 2009-04-10 20:08:13 UTC (rev 12264) @@ -337,7 +337,7 @@ uses Consts, - JvJCLUtils, JvJVCLUtils, JvThemes; + JvJCLUtils, JvJVCLUtils, JvVCL5Utils, JvThemes; {$R JvTMTimeLine.res} @@ -580,7 +580,7 @@ Self.Date := Delta; end; -function TJvCustomTMTimeline.GetRectForDate(ADate: TDate): TRect; +function TJvCustomTMTimeline.GetRectForDate(ADate: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate): TRect; begin // all rects are the same size... Result := Rect(0, 0, DayWidth, ClientHeight + 1); @@ -593,7 +593,7 @@ OffsetRect(Result, ButtonWidth, 0); end; -function TJvCustomTMTimeline.DateFromPos(APos: Integer): TDate; +function TJvCustomTMTimeline.DateFromPos(APos: Integer): {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate; var Tmp: Integer; begin @@ -785,7 +785,7 @@ end; end; -procedure TJvCustomTMTimeline.DrawImage(ACanvas: TCanvas; ADate: TDate; const ARect: TRect); +procedure TJvCustomTMTimeline.DrawImage(ACanvas: TCanvas; ADate: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate; const ARect: TRect); var I, X, Y: Integer; begin @@ -826,7 +826,7 @@ end; end; -procedure TJvCustomTMTimeline.SetFirstDate(const Value: TDate); +procedure TJvCustomTMTimeline.SetFirstDate(const Value: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate); begin if Trunc(FDate) <> Trunc(Value) then begin @@ -859,7 +859,7 @@ Invalidate; end; -procedure TJvCustomTMTimeline.SetSelDate(const Value: TDate); +procedure TJvCustomTMTimeline.SetSelDate(const Value: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate); var R: TRect; begin @@ -941,14 +941,14 @@ FImages := nil; end; -function TJvCustomTMTimeline.GetImageIndex(ADate: TDate): Integer; +function TJvCustomTMTimeline.GetImageIndex(ADate: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate): Integer; begin Result := FDateImages.IndexOf(IntToStr(Trunc(ADate))); if Result > -1 then Result := Integer(FDateImages.Objects[Result]); end; -procedure TJvCustomTMTimeline.SetImageIndex(ADate: TDate; +procedure TJvCustomTMTimeline.SetImageIndex(ADate: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate; const Value: Integer); var I: Integer; @@ -960,7 +960,7 @@ Invalidate; end; -function TJvCustomTMTimeline.GetObjects(ADate: TDate): TObject; +function TJvCustomTMTimeline.GetObjects(ADate: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate): TObject; var I: Integer; begin @@ -970,7 +970,7 @@ Result := FObjects.Objects[I]; end; -procedure TJvCustomTMTimeline.SetObjects(ADate: TDate; const Value: TObject); +procedure TJvCustomTMTimeline.SetObjects(ADate: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate; const Value: TObject); var I: Integer; begin @@ -1092,7 +1092,7 @@ FRightClickSelect := Value; end; -procedure TJvCustomTMTimeline.SetMaxDate(const Value: TDate); +procedure TJvCustomTMTimeline.SetMaxDate(const Value: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate); begin if Trunc(FMaxDate) <> Trunc(Value) then begin @@ -1106,7 +1106,7 @@ end; end; -procedure TJvCustomTMTimeline.SetMinDate(const Value: TDate); +procedure TJvCustomTMTimeline.SetMinDate(const Value: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate); begin if Trunc(FMinDate) <> Trunc(Value) then begin @@ -1145,7 +1145,7 @@ FDateImages.Clear; end; -function TJvCustomTMTimeline.GetLastVisibleDate: TDate; +function TJvCustomTMTimeline.GetLastVisibleDate: {$IFNDEF RTL200_UP}Controls.{$ENDIF ~RTL200_UP}TDate; var Tmp: Integer; begin Modified: trunk/jvcl/run/JvVCL5Utils.pas =================================================================== --- trunk/jvcl/run/JvVCL5Utils.pas 2009-04-01 23:17:57 UTC (rev 12263) +++ trunk/jvcl/run/JvVCL5Utils.pas 2009-04-10 20:08:13 UTC (rev 12264) @@ -192,10 +192,16 @@ // Misc function GetMonitorWorkareaRect(Monitor: TMonitor): TRect; +{$IFNDEF RTL200_UP} type UTF8String = type string; +{$ENDIF ~RTL200_UP} +{$IFNDEF DELPHI6_UP} function Utf8Decode(const S: UTF8String): WideString; +function Utf8Encode(const S: WideString): UTF8String; +{$ENDIF ~DELPHI6_UP} + function Utf8ToAnsi(const S: UTF8String): string; // System @@ -289,7 +295,7 @@ uses CommCtrl, - JclSysUtils; + JclStringConversions, JclSysUtils; var GlobalCollectionHooked: Boolean = False; @@ -1205,6 +1211,10 @@ Result := Utf8Decode(S); end; +function Utf8Encode(const S: WideString): UTF8String; +begin + Result := WideStringToUTF8(S); +end; //=== { TCustomImageList } =================================================== Modified: trunk/jvcl/run/JvgXMLSerializer.pas =================================================================== --- trunk/jvcl/run/JvgXMLSerializer.pas 2009-04-01 23:17:57 UTC (rev 12263) +++ trunk/jvcl/run/JvgXMLSerializer.pas 2009-04-10 20:08:13 UTC (rev 12264) @@ -178,7 +178,7 @@ uses {$IFDEF USEJVCL} - JvResources, + JvVCL5Utils, JvResources, {$ENDIF USEJVCL} JvgUtils; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |