Results 1 to 2 of 2

Thread: PaintSmart variable removal [minor]

  1. #1
    Join Date
    May 2007
    Location
    Everywhere
    Posts
    1,428
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default PaintSmart variable removal [minor]

    Minor problem, the thing works just I keep getting "variable unused" x2

    This is my fix if anyone wants to apply it, in fact you can even remove the commented variables out, I just left it commented so I could both test it and show you guys what needs removing:

    Simba Code:
    {*******************************************************************************
    procedure SMART_DrawBoxEx(Clear: boolean; Box: TBox; color: TColor);
    Contributors: Sir R. Magician, caused, mastaraymond
    Description: Draws a TBox onto the SMART Debug canvas
    *******************************************************************************}

    procedure SMART_DrawBoxEx(Clear: boolean; Box: TBox; color: TColor);
    {$IFDEF SMART}
    var
      drawing : TBitmap;
      //TP : TPoint;
      //B: TBox;
    begin

      drawing := TBitmap.Create;
      drawing.canvas.handle := SmartGetDebugDC;
      drawing.canvas.Pen.Color := color;

      if Clear then ClearRSCanvas(drawing.canvas);

      drawing.canvas.moveto(Box.x1,Box.y1);
      drawing.canvas.LineTo(Box.x2,Box.y1);
      drawing.canvas.LineTo(Box.x2,Box.y2);
      drawing.canvas.LineTo(Box.x1,Box.y2);
      drawing.canvas.LineTo(Box.x1,Box.y1);


      try
        FreeBitmap(drawing);
      except end;

    {$ELSE}
    begin
    {$ENDIF}

    end;

  2. #2
    Join Date
    Apr 2008
    Location
    Marquette, MI
    Posts
    15,252
    Mentioned
    138 Post(s)
    Quoted
    680 Post(s)

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •