diff --git a/components/jvcllaz/examples/JvItemViewer/MainFrm.pas b/components/jvcllaz/examples/JvItemViewer/MainFrm.pas index 8eb70e220..04ef51109 100644 --- a/components/jvcllaz/examples/JvItemViewer/MainFrm.pas +++ b/components/jvcllaz/examples/JvItemViewer/MainFrm.pas @@ -33,7 +33,7 @@ unit MainFrm; interface uses - Windows, Messages, SysUtils, Classes, Graphics, Forms, Controls, + SysUtils, Classes, Graphics, Forms, Controls, Dialogs, StdCtrls, ExtCtrls, ImgList, ComCtrls, Menus, // if you have units that supports other image formats, add them here *before* including JvItemViewer // GraphicEx, // http://www.delphi-gems.com/Graphics.php#GraphicEx @@ -113,8 +113,6 @@ var implementation uses - JvConsts, // for clMoneyGreen - CommCtrl, //Consts, ViewerFrm; {$R *.lfm} @@ -126,7 +124,7 @@ procedure TfrmMain.DoITV3DrawItem(Sender: TObject; AIndex: Integer; AState: TCus var AColor: TColor; begin - AColor := TColor(ITV3.Items[AIndex].Data); + AColor := TColor(PtrInt(ITV3.Items[AIndex].Data)); ACanvas.Brush.Color := AColor; ACanvas.FillRect(ItemRect); ACanvas.Pen.Style := psSolid; @@ -271,7 +269,7 @@ begin for I := 0 to $3FFE do begin J := ($3FFE - I) + 500; - ITV3.Items[I].Data := Pointer(RGB(Random(J) mod 256, Random(J) mod 256, Random(J) mod 256)); + ITV3.Items[I].Data := Pointer(PtrInt(RGBToColor(Random(J) mod 256, Random(J) mod 256, Random(J) mod 256))); end; end; @@ -414,7 +412,7 @@ end; procedure TfrmMain.DoITV3Click(Sender: TObject); begin if (ITV3.SelectedIndex >= 0) and (ITV3.SelectedIndex < ITV3.Count) then - StatusBar1.Panels[0].Text := ColorToString(TColor(ITV3.Items[ITV3.SelectedIndex].Data)); + StatusBar1.Panels[0].Text := ColorToString(TColor(PtrInt(ITV3.Items[ITV3.SelectedIndex].Data))); end; procedure TfrmMain.DoITV2GetCaption(Sender: TObject; ImageIndex: Integer; @@ -509,7 +507,7 @@ procedure TfrmMain.DoITV3ItemHint(Sender: TObject; Index: Integer; var AColor: TColor; begin - AColor := TColor(ITV3.Items[Index].Data); + AColor := TColor(PtrInt(ITV3.Items[Index].Data)); HintInfo.HintColor := AColor; HintInfo.HintStr := ColorToString(AColor); Handled := true; diff --git a/components/jvcllaz/examples/JvTMTimeLine/SimpleTLTest1.lpi b/components/jvcllaz/examples/JvTMTimeLine/SimpleTLTest1.lpi index e361fca81..47b13d635 100644 --- a/components/jvcllaz/examples/JvTMTimeLine/SimpleTLTest1.lpi +++ b/components/jvcllaz/examples/JvTMTimeLine/SimpleTLTest1.lpi @@ -1,7 +1,7 @@ - + @@ -20,9 +20,10 @@ - - - + + + + diff --git a/components/jvcllaz/examples/JvTMTimeLine/TMTimeLineMainFormU.lfm b/components/jvcllaz/examples/JvTMTimeLine/TMTimeLineMainFormU.lfm index 28f26ef33..b848a2927 100644 --- a/components/jvcllaz/examples/JvTMTimeLine/TMTimeLineMainFormU.lfm +++ b/components/jvcllaz/examples/JvTMTimeLine/TMTimeLineMainFormU.lfm @@ -22,13 +22,13 @@ object TMTimeLineMainForm: TTMTimeLineMainForm Scaled = False object Panel1: TPanel Left = 0 - Height = 335 - Top = 224 + Height = 339 + Top = 225 Width = 926 Align = alBottom AutoSize = True BevelOuter = bvNone - ClientHeight = 335 + ClientHeight = 339 ClientWidth = 926 TabOrder = 0 TabStop = True @@ -36,11 +36,11 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = LbImages AnchorSideTop.Control = Panel1 AnchorSideRight.Side = asrBottom - Left = 4 + Left = 8 Height = 15 - Top = 4 + Top = 8 Width = 41 - BorderSpacing.Top = 4 + BorderSpacing.Top = 8 Caption = 'Images:' ParentColor = False end @@ -48,9 +48,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = gbDates AnchorSideTop.Control = gbDates AnchorSideTop.Side = asrBottom - Left = 597 + Left = 601 Height = 15 - Top = 188 + Top = 192 Width = 112 BorderSpacing.Top = 24 Caption = 'Keyboard navigation:' @@ -60,9 +60,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = LblKeyboardNavigation AnchorSideTop.Control = LblKeyboardNavigation AnchorSideTop.Side = asrBottom - Left = 613 + Left = 617 Height = 30 - Top = 207 + Top = 211 Width = 181 BorderSpacing.Left = 16 BorderSpacing.Top = 4 @@ -73,9 +73,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = Label18 AnchorSideTop.Control = Label18 AnchorSideTop.Side = asrBottom - Left = 613 + Left = 617 Height = 30 - Top = 241 + Top = 245 Width = 181 BorderSpacing.Top = 4 Caption = 'Ctrl+Left/Right arrow:'#13#10#9'move Large Change days' @@ -85,9 +85,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = Label19 AnchorSideTop.Control = Label19 AnchorSideTop.Side = asrBottom - Left = 613 + Left = 617 Height = 30 - Top = 275 + Top = 279 Width = 173 BorderSpacing.Top = 4 Caption = 'Shift+Left/Right arrow:'#13#10#9'move selection one day' @@ -97,12 +97,13 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = gbAppearance AnchorSideLeft.Side = asrBottom AnchorSideTop.Control = gbWidths - Left = 597 + Left = 601 Height = 160 - Top = 4 + Top = 8 Width = 230 AutoSize = True BorderSpacing.Left = 24 + BorderSpacing.Right = 8 Caption = ' Dates: ' ClientHeight = 140 ClientWidth = 226 @@ -233,7 +234,6 @@ object TMTimeLineMainForm: TTMTimeLineMainForm Min = -1 Position = -1 TabOrder = 3 - Wrap = False end object dtpImageDate: TDateTimePicker AnchorSideLeft.Control = edImageNo @@ -285,9 +285,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = gbWidths AnchorSideLeft.Side = asrBottom AnchorSideTop.Control = gbWidths - Left = 315 + Left = 319 Height = 194 - Top = 4 + Top = 8 Width = 258 AutoSize = True BorderSpacing.Left = 24 @@ -462,9 +462,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Side = asrBottom AnchorSideTop.Control = gbFonts AnchorSideBottom.Side = asrBottom - Left = 369 + Left = 373 Height = 94 - Top = 206 + Top = 210 Width = 145 AutoSize = True BorderSpacing.Left = 24 @@ -513,9 +513,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = gbWidths AnchorSideTop.Control = gbAppearance AnchorSideTop.Side = asrBottom - Left = 100 + Left = 104 Height = 129 - Top = 206 + Top = 210 Width = 245 AutoSize = True BorderSpacing.Top = 8 @@ -627,9 +627,9 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideLeft.Control = LbImages AnchorSideLeft.Side = asrBottom AnchorSideTop.Control = LblImages - Left = 100 + Left = 104 Height = 161 - Top = 4 + Top = 8 Width = 191 AutoSize = True BorderSpacing.Left = 12 @@ -794,7 +794,6 @@ object TMTimeLineMainForm: TTMTimeLineMainForm OnClick = udDayWidthClick Position = 19 TabOrder = 5 - Wrap = False end object edPenWidth: TEdit AnchorSideLeft.Control = edScrollSmall @@ -825,7 +824,6 @@ object TMTimeLineMainForm: TTMTimeLineMainForm OnClick = udPenWidthClick Position = 2 TabOrder = 7 - Wrap = False end object edScrollSmall: TEdit AnchorSideTop.Control = gbWidths @@ -855,7 +853,6 @@ object TMTimeLineMainForm: TTMTimeLineMainForm OnClick = udScrollSmallClick Position = 7 TabOrder = 1 - Wrap = False end object edScrollLarge: TEdit AnchorSideLeft.Control = edScrollSmall @@ -887,7 +884,6 @@ object TMTimeLineMainForm: TTMTimeLineMainForm OnClick = udScrollLargeClick Position = 30 TabOrder = 3 - Wrap = False end object edButtonWidth: TEdit AnchorSideLeft.Control = edScrollSmall @@ -920,7 +916,6 @@ object TMTimeLineMainForm: TTMTimeLineMainForm OnClick = udButtonWidthClick Position = 12 TabOrder = 9 - Wrap = False end end object LbImages: TListBox @@ -929,12 +924,12 @@ object TMTimeLineMainForm: TTMTimeLineMainForm AnchorSideTop.Side = asrBottom AnchorSideBottom.Control = Panel1 AnchorSideBottom.Side = asrBottom - Left = 4 + Left = 8 Height = 312 - Top = 23 + Top = 27 Width = 84 Anchors = [akTop, akLeft, akBottom] - BorderSpacing.Left = 4 + BorderSpacing.Left = 8 BorderSpacing.Top = 4 ItemHeight = 0 OnDrawItem = LbImagesDrawItem @@ -949,7 +944,7 @@ object TMTimeLineMainForm: TTMTimeLineMainForm Hint = 'Displays info about the control' Top = 568 Width = 926 - BorderSpacing.Top = 9 + BorderSpacing.Top = 4 Panels = < item Width = 300 diff --git a/components/jvcllaz/run/JvCore/JvJVCLUtils.pas b/components/jvcllaz/run/JvCore/JvJVCLUtils.pas index 95a03ccff..2d0cc461d 100644 --- a/components/jvcllaz/run/JvCore/JvJVCLUtils.pas +++ b/components/jvcllaz/run/JvCore/JvJVCLUtils.pas @@ -7079,7 +7079,6 @@ type R, G, B, A: byte; end; var - i: Integer; c: Int32; begin if AText[1] = '#' then AText[1] := '$'; diff --git a/components/jvcllaz/run/JvCustomControls/JvCustomItemViewer.pas b/components/jvcllaz/run/JvCustomControls/JvCustomItemViewer.pas index 32ec1bd3b..2c5097da1 100644 --- a/components/jvcllaz/run/JvCustomControls/JvCustomItemViewer.pas +++ b/components/jvcllaz/run/JvCustomControls/JvCustomItemViewer.pas @@ -946,7 +946,7 @@ begin BeginUpdate; try for I := 0 to Count - 1 do - if (Integer(Items[I]) <> Msg.LParam) and + if (PtrInt(Items[I]) <> Msg.LParam) and (cdsSelected in Items[I].State) then Items[I].State := Items[I].State - [cdsSelected]; finally diff --git a/components/jvcllaz/run/JvCustomControls/JvImageListViewer.pas b/components/jvcllaz/run/JvCustomControls/JvImageListViewer.pas index 6646e5473..0ef8602f1 100644 --- a/components/jvcllaz/run/JvCustomControls/JvImageListViewer.pas +++ b/components/jvcllaz/run/JvCustomControls/JvImageListViewer.pas @@ -140,7 +140,7 @@ type implementation uses - CommCtrl, LCLType, LCLProc, LCLIntf, + LCLType, LCLProc, LCLIntf, Math, JvJCLUtils, JvJVCLUtils;