diff options
author | Andrew Haines <andrewd207@aol.com> | 2015-02-01 23:17:27 -0500 |
---|---|---|
committer | Andrew Haines <andrewd207@aol.com> | 2015-02-01 23:17:27 -0500 |
commit | d351655a167dc6afe70ed659561ef8b3a4019305 (patch) | |
tree | 3843e8f137929b13a74ba787ec6f9f5541fc2427 /src/gui/fpg_scrollbar.pas | |
parent | c7fc66e330b4665843e195436e7e5095de5dbdfc (diff) | |
parent | 0955cc8f881782e1565447f04a0afb774e1237aa (diff) | |
download | fpGUI-d351655a167dc6afe70ed659561ef8b3a4019305.tar.xz |
Merge branch 'develop' of https://github.com/graemeg/fpGUI into develop
Fixed xml conflicts of lpi's manually
Conflicts:
examples/gui/filedialog/filedialog.lpi
examples/gui/modalforms/modalforms.lpi
Diffstat (limited to 'src/gui/fpg_scrollbar.pas')
-rw-r--r-- | src/gui/fpg_scrollbar.pas | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/gui/fpg_scrollbar.pas b/src/gui/fpg_scrollbar.pas index 7fd5de64..fbe20006 100644 --- a/src/gui/fpg_scrollbar.pas +++ b/src/gui/fpg_scrollbar.pas @@ -36,7 +36,7 @@ uses type TScrollNotifyEvent = procedure(Sender: TObject; position: integer) of object; - TfpgScrollStyle = (ssNone, ssHorizontal, ssVertical, ssAutoBoth); + TfpgScrollStyle = (ssNone, ssHorizontal, ssVertical, ssAutoBoth, ssHorizVisible, ssVertiVisible, ssBothVisible); TfpgScrollBarPart = (sbpNone, sbpUpBack, sbpPageUpBack, sbpSlider, sbpDownForward, sbpPageDownForward); @@ -134,7 +134,6 @@ end; procedure TfpgScrollBar.HandlePaint; begin - Canvas.BeginDraw; // Do not remove - Scrollbars do painting outside HandlePaint as well! if Orientation = orVertical then begin DrawButton(0, 0, Width, Width, 'sys.sb.up', (FScrollbarDownPart = sbpUpBack) and (FPosition <> FMin), (FPosition <> FMin) and (Parent.Enabled)); @@ -145,9 +144,7 @@ begin DrawButton(0, 0, Height, Height, 'sys.sb.left', (FScrollbarDownPart = sbpUpBack) and (FPosition <> FMin), (FPosition <> FMin) and (Parent.Enabled)); DrawButton(Width-Height, 0, Height, Height, 'sys.sb.right', (FScrollbarDownPart = sbpDownForward) and (FPosition <> FMax), (FPosition <> FMax) and (Parent.Enabled)); end; - DrawSlider(FRecalc); - Canvas.EndDraw; // Do not remove - Scrollbars do painting outside HandlePaint as well! FRecalc := False; end; @@ -162,7 +159,7 @@ begin if not HasHandle then Exit; //==> FRecalc := True; - Invalidate;// DrawSlider(True); + Invalidate; end; procedure TfpgScrollBar.LineUp; @@ -219,7 +216,7 @@ begin FPosition := AValue; if HasHandle then - Invalidate;// DrawSlider(False); + Invalidate; end; procedure TfpgScrollBar.Step(ASteps: Integer); @@ -576,7 +573,7 @@ begin FSliderPos := area; if ppos <> FSliderPos then - Invalidate; // DrawSlider(False); + Invalidate; if area <> 0 then newp := FMin + Trunc((FMax - FMin) * (FSliderPos / area)) @@ -609,7 +606,7 @@ begin if Visible then begin FRecalc := True; - Invalidate; // DrawSlider(True); + Invalidate; end; if Assigned(FOnScroll) then |