diff --git a/components/jvcllaz/examples/JvLED/JvLEDDemo.lpi b/components/jvcllaz/examples/JvLED/JvLEDDemo.lpi
index e48cc0482..5080ac236 100644
--- a/components/jvcllaz/examples/JvLED/JvLEDDemo.lpi
+++ b/components/jvcllaz/examples/JvLED/JvLEDDemo.lpi
@@ -4,9 +4,6 @@
-
-
-
@@ -16,7 +13,6 @@
-
@@ -55,9 +51,10 @@
-
+
+
diff --git a/components/jvcllaz/examples/JvLED/JvLEDDemo.lpr b/components/jvcllaz/examples/JvLED/JvLEDDemo.lpr
index 213d7b464..2b182fe76 100644
--- a/components/jvcllaz/examples/JvLED/JvLEDDemo.lpr
+++ b/components/jvcllaz/examples/JvLED/JvLEDDemo.lpr
@@ -7,6 +7,7 @@ uses
{$R *.res}
begin
+ Application.Scaled:=True;
Application.Initialize;
Application.CreateForm(TLEDDemoMain, LEDDemoMain);
Application.Run;
diff --git a/components/jvcllaz/packages/JvMMLazD.lpk b/components/jvcllaz/packages/JvMMLazD.lpk
index 4c28634f1..b6e4cb608 100644
--- a/components/jvcllaz/packages/JvMMLazD.lpk
+++ b/components/jvcllaz/packages/JvMMLazD.lpk
@@ -9,8 +9,9 @@
+
-
+
diff --git a/components/jvcllaz/packages/JvMMLazR.lpk b/components/jvcllaz/packages/JvMMLazR.lpk
index 727c55302..c46d72286 100644
--- a/components/jvcllaz/packages/JvMMLazR.lpk
+++ b/components/jvcllaz/packages/JvMMLazR.lpk
@@ -8,8 +8,9 @@
+
-
+
diff --git a/components/jvcllaz/packages/jvhmilazd.lpk b/components/jvcllaz/packages/jvhmilazd.lpk
index 07599b8f5..806cc48b9 100644
--- a/components/jvcllaz/packages/jvhmilazd.lpk
+++ b/components/jvcllaz/packages/jvhmilazd.lpk
@@ -9,8 +9,9 @@
+
-
+
+
-
+
FNumGlyphs) or (FIndex > FStop) then
+ FIndex := FStart;
+ end;
+ tdBack:
+ begin
+ Dec(FIndex);
+ if (FIndex < 0) or (FIndex < FStart) then
+ FIndex := FStop;
+ end;
+ tdFwdBack, tdBackFwd:
+ begin
+ if FGoingUp then
+ begin
+ if (FIndex >= FStop) then
+ begin
+ FGoingUp := False;
+ Dec(FIndex);
+ end
+ else
+ Inc(FIndex);
+ end
+ else
+ begin
+ if FIndex <= FStart then
+ begin
+ FGoingUp := True;
+ Inc(FIndex);
+ end
+ else
+ Dec(FIndex);
+ end;
+ end;
+ end;
+ Refresh;
+end;
+
+procedure TJvCustomBmpAnimator.SetStart(Value: Integer);
+begin
+ if FStart <> Value then
+ begin
+ FStart := Value;
+ if FStart > FStop then
+ FStart := FStop;
+ if FStart >= FNumGlyphs then
+ FStart := FNumGlyphs - 1;
+ if FStart < 0 then
+ FStart := 0;
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.SetStop(Value: Integer);
+begin
+ if FStop <> Value then
+ begin
+ FStop := Value;
+ if FStop < FStart then
+ FStop := FStart;
+ if FStop >= FNumGlyphs then
+ FStop := FNumGlyphs - 1;
+ if FStop < 0 then
+ FStop := 0;
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.SetAutoSize(Value: Boolean);
+begin
+ if FAutoSize <> Value then
+ begin
+ FAutoSize := Value;
+ if FAutoSize and Assigned(FImageList) then
+ begin
+ Width := FImageList.Width;
+ Height := FImageList.Height;
+ end;
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.SetTransparent(Value: Boolean);
+begin
+ if FTransparent <> Value then
+ begin
+ FTransparent := Value;
+ Repaint;
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.Notification(AComponent: TComponent; AOperation: TOperation);
+begin
+ inherited Notification(AComponent, AOperation);
+ if (AOperation = opRemove) and (AComponent = FImageList) then
+ SetImage(nil);
+end;
+
+procedure TJvCustomBmpAnimator.SetImage(Value: TCustomImageList);
+begin
+ if FImageList <> nil then
+ SetNumGlyphs(0);
+
+ ReplaceImageListReference(Self, Value, FImageList, FImageChangeLink);
+ if FImageList <> nil then
+ SetNumGlyphs(FImageList.Count)
+ else
+ Active := False;
+ Repaint;
+end;
+
+procedure TJvCustomBmpAnimator.SetActive(Value: Boolean);
+begin
+{ if not Assigned(FImageList) then
+ Value := False;}
+ if FActive <> Value then
+ begin
+ FActive := Value;
+ FTimer.Enabled := FActive;
+ FIndex := FStart;
+ end;
+ Repaint;
+end;
+
+procedure TJvCustomBmpAnimator.SetNumGlyphs(Value: Integer);
+begin
+ if FNumGlyphs <> Value then
+ begin
+ FNumGlyphs := Value;
+ SetStop(FNumGlyphs - 1);
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.SetSpeed(Value: Integer);
+begin
+ if FSpeed <> Value then
+ begin
+ FSpeed := Value;
+ FTimer.Interval := 1000 div FSpeed;
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.SetCenter(Value: Boolean);
+begin
+ if FCenter <> Value then
+ begin
+ FCenter := Value;
+ Invalidate;
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.SetDirection(Value: TJvAnimateDirection);
+begin
+ if FDirection <> Value then
+ begin
+ FDirection := Value;
+ case FDirection of
+ tdForward, tdFwdBack:
+ begin
+ FGoingUp := True;
+ FIndex := FStart;
+ end;
+ tdBack, tdBackFwd:
+ begin
+ FGoingUp := False;
+ FIndex := FStop;
+ end;
+ end;
+ end;
+end;
+
+procedure TJvCustomBmpAnimator.SetPosition(Value: Integer);
+begin
+ FPosition := Value;
+ if FPosition > FNumGlyphs - 1 then
+ FPosition := FNumGlyphs - 1;
+ Invalidate;
+end;
+
+procedure TJvCustomBmpAnimator.Paint;
+var
+ dX, dY: Integer;
+begin
+ if Assigned(FImageList) then
+ begin
+ if FCenter then
+ begin
+ dX := (Width - FImageList.Width) div 2;
+ dY := (Height - FImageList.Height) div 2;
+ end
+ else
+ begin
+ dX := 0;
+ dY := 0;
+ end;
+ if not FTransparent then
+ begin
+ Canvas.Brush.Color := Color;
+ Canvas.FillRect(ClientRect);
+ end
+ else
+ Canvas.Brush.Style := bsClear;
+ FImageList.Draw(Canvas, dX, dY, FIndex);
+
+ if not Active then
+ FIndex := FPosition;
+ FImageList.Draw(Canvas, dX, dY, FIndex)
+ end;
+ if csDesigning in ComponentState then
+ with Canvas do
+ begin
+ Brush.Color := clBlack;
+ FrameRect( GetClientRect);
+ end;
+end;
+
+end.