From 3f7fa819e2cecc29906b97764e46edde52282df8 Mon Sep 17 00:00:00 2001 From: christian_u Date: Fri, 6 Feb 2009 06:16:36 +0000 Subject: [PATCH] ctl3d removed git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@700 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- components/tvplanit/source/vpbaseds.pas | 3 +- components/tvplanit/source/vpcalendar.pas | 39 +++++--------------- components/tvplanit/source/vpcontactgrid.pas | 2 - components/tvplanit/source/vpdateedit.pas | 4 -- components/tvplanit/source/vpdayview.pas | 2 - components/tvplanit/source/vpedpop.pas | 8 ---- components/tvplanit/source/vpnavbar.pas | 19 +--------- components/tvplanit/source/vptasklist.pas | 2 - components/tvplanit/source/vpweekview.pas | 2 - 9 files changed, 12 insertions(+), 69 deletions(-) diff --git a/components/tvplanit/source/vpbaseds.pas b/components/tvplanit/source/vpbaseds.pas index 63b86e64c..10861834a 100644 --- a/components/tvplanit/source/vpbaseds.pas +++ b/components/tvplanit/source/vpbaseds.pas @@ -322,8 +322,7 @@ type property ControlLink: TVpControlLink read FControlLink write SetControlLink; property Color; - property Ctl3D; - property Font; + property Font; property ParentColor; property ParentFont; property ParentShowHint; diff --git a/components/tvplanit/source/vpcalendar.pas b/components/tvplanit/source/vpcalendar.pas index fa5a71453..03d4d09d5 100644 --- a/components/tvplanit/source/vpcalendar.pas +++ b/components/tvplanit/source/vpcalendar.pas @@ -215,7 +215,6 @@ type {-calcualte new sizes for rows and columns} {VCL control methods} - procedure CMCtl3DChanged(var Msg : TMessage); message CM_CTL3DCHANGED; procedure CMEnter(var Msg : TMessage); message CM_ENTER; procedure CMExit(var Msg : TMessage); message CM_EXIT; procedure CMFontChanged(var Msg : TMessage); message CM_FONTCHANGED; @@ -333,7 +332,6 @@ type property BorderStyle; property Color; property Colors; - property Ctl3D; property Cursor; property DateFormat; property DayNameWidth; @@ -342,7 +340,6 @@ type property Enabled; property Font; property Options; - property ParentCtl3D; property ParentFont; property ParentShowHint; property PopupMenu; @@ -719,12 +716,12 @@ begin FillChar(clRowCol, SizeOf(clRowCol), #0); {set the way the buttons should look} - clBtnLeft.Flat := not Ctl3D and not clPopup; - clBtnRevert.Flat := not Ctl3D and not clPopup; - clBtnRight.Flat := not Ctl3D and not clPopup; - clBtnToday.Flat := not Ctl3D and not clPopup; - clBtnNextYear.Flat := not Ctl3D and not clPopup; - clBtnPrevYear.Flat := not Ctl3D and not clPopup; + clBtnLeft.Flat := {not Ctl3D and} not clPopup; + clBtnRevert.Flat := {not Ctl3D and} not clPopup; + clBtnRight.Flat := {not Ctl3D and} not clPopup; + clBtnToday.Flat := {not Ctl3D and} not clPopup; + clBtnNextYear.Flat := {not Ctl3D and} not clPopup; + clBtnPrevYear.Flat := {not Ctl3D and} not clPopup; clBtnRevert.Visible := cdoShowRevert in FOptions; clBtnToday.Visible := cdoShowToday in FOptions; @@ -781,22 +778,6 @@ begin end; {=====} -procedure TVpCustomCalendar.CMCtl3DChanged(var Msg : TMessage); -begin - inherited; - - if (csLoading in ComponentState) or not HandleAllocated then - Exit; - - if NewStyleControls and (FBorderStyle = bsSingle) then - RecreateWnd{$IFDEF LCL}(Self){$ENDIF}; - - calReCalcSize (False); - - Invalidate; -end; -{=====} - procedure TVpCustomCalendar.CMEnter(var Msg : TMessage); var R : TRect; @@ -940,7 +921,7 @@ begin end; end; {$ENDIF} - if NewStyleControls and (Ctl3D or clPopup) and (FBorderStyle = bsSingle) then begin + if NewStyleControls and ({Ctl3D or }clPopup) and (FBorderStyle = bsSingle) then begin if not clPopup then Params.Style := Params.Style and not WS_BORDER; Params.ExStyle := Params.ExStyle or WS_EX_CLIENTEDGE; @@ -1624,13 +1605,13 @@ var procedure DrawLine; begin - if (not Ctl3D) then begin +// if (not Ctl3D) then begin RenderCanvas.Pen.Color := LineColor; TPSMoveTo (RenderCanvas, Angle, RenderIn, RealLeft, clRowCol[1,0].Bottom-3 + RealTop); TPSLineTo (RenderCanvas, Angle, RenderIn, RealRight, clRowCol[1,0].Bottom-3 + RealTop); - end else if Ctl3D then begin +{ end else if Ctl3D then begin RenderCanvas.Pen.Color := BevelHighlight; TPSMoveTo (RenderCanvas, Angle, RenderIn, RealLeft, clRowCol[1,0].Bottom-3 + RealTop); @@ -1641,7 +1622,7 @@ var RealLeft, clRowCol[1,0].Bottom-2 + RealTop); TPSLineTo (RenderCanvas, Angle, RenderIn, RealRight, clRowCol[1,0].Bottom-2 + RealTop); - end; + end; } end; procedure DrawDay(R, C, I : Integer; Grayed : Boolean); diff --git a/components/tvplanit/source/vpcontactgrid.pas b/components/tvplanit/source/vpcontactgrid.pas index 3417bf3fc..d571d1729 100644 --- a/components/tvplanit/source/vpcontactgrid.pas +++ b/components/tvplanit/source/vpcontactgrid.pas @@ -322,8 +322,6 @@ constructor TVpCGInPlaceEdit.Create(AOwner: TComponent); begin inherited Create(AOwner); field := ''; - ParentCtl3D := False; - Ctl3D := False; TabStop := False; BorderStyle := bsNone; {$IFDEF VERSION4} diff --git a/components/tvplanit/source/vpdateedit.pas b/components/tvplanit/source/vpdateedit.pas index ea42eda5b..d46c07e8b 100644 --- a/components/tvplanit/source/vpdateedit.pas +++ b/components/tvplanit/source/vpdateedit.pas @@ -142,7 +142,6 @@ type property BorderStyle; property CharCase; property Color; - property Ctl3D; property Cursor; property DragCursor; property DragMode; @@ -154,7 +153,6 @@ type property HideSelection; {$ENDIF} property ParentColor; - property ParentCtl3D; property ParentFont; property ParentShowHint; property PopupCalColors; @@ -413,8 +411,6 @@ begin Calendar.Height := FPopupCalHeight; Calendar.Width := FPopupCalWidth; Calendar.WeekStarts := FWeekStarts; - Calendar.ParentCtl3D := False; - Calendar.Ctl3D := Ctl3D; Calendar.Font.Assign(FPopupCalFont); end; diff --git a/components/tvplanit/source/vpdayview.pas b/components/tvplanit/source/vpdayview.pas index 471798c73..5ff027027 100644 --- a/components/tvplanit/source/vpdayview.pas +++ b/components/tvplanit/source/vpdayview.pas @@ -526,8 +526,6 @@ uses constructor TVpDvInPlaceEdit.Create(AOwner: TComponent); begin inherited Create(AOwner); - ParentCtl3D := False; - Ctl3D := False; TabStop := False; BorderStyle := bsNone; DoubleBuffered := False; diff --git a/components/tvplanit/source/vpedpop.pas b/components/tvplanit/source/vpedpop.pas index dd4f6d36f..118ff74bf 100644 --- a/components/tvplanit/source/vpedpop.pas +++ b/components/tvplanit/source/vpedpop.pas @@ -186,14 +186,6 @@ begin FButton.Width := FButton.Glyph.Width + 6; FButton.Left := Width - FButton.Width; FButton.Top := 0; - end else if Ctl3D then begin - FButton.Height := H; - FButton.Width := (FButton.Height div 4) * 3; - if Assigned(FButton.Glyph) then - if FButton.Width < FButton.Glyph.Width + 6 then - FButton.Width := FButton.Glyph.Width + 6; - FButton.Left := Width - FButton.Width - 4; - FButton.Top := 0; end else begin FButton.Height := H - 2; FButton.Width := (FButton.Height div 4) * 3; diff --git a/components/tvplanit/source/vpnavbar.pas b/components/tvplanit/source/vpnavbar.pas index 789d186d3..fb3519f67 100644 --- a/components/tvplanit/source/vpnavbar.pas +++ b/components/tvplanit/source/vpnavbar.pas @@ -306,7 +306,6 @@ type procedure WMNCHitTest(var Msg : TWMNCHitTest); message WM_NCHITTEST; procedure WMSetCursor(var Msg : TWMSetCursor); message WM_SETCURSOR; {$ELSE} - procedure CMCtl3DChanged(var Msg : TLMessage); message CM_CTL3DCHANGED; procedure CMFontChanged(var Message: TLMessage); message CM_FONTCHANGED; procedure CMParentColorChanged(var Message: TLMessage); message CM_PARENTCOLORCHANGED; {windows message response methods} @@ -491,7 +490,6 @@ type property DragKind; {$ENDIF} property Align; - property Ctl3D; property DragCursor; property Enabled; property Font; @@ -507,7 +505,6 @@ type property OnMouseUp; property OnStartDrag; property ParentColor; - property ParentCtl3D; property ParentFont; property ParentShowHint; property PopupMenu; @@ -745,8 +742,6 @@ end; constructor TVpRenameEdit.Create(AOwner : TComponent); begin inherited Create(AOwner); - - Ctl3D := False; Visible := False; WantReturns := False; FolderIndex := -1; @@ -1151,18 +1146,6 @@ begin end; {=====} -procedure TVpCustomNavBar.CMCtl3DChanged(var Msg : {$IFDEF LCL}TLMessage{$ELSE}TMessage{$ENDIF}); -begin - if (csLoading in ComponentState) or not HandleAllocated then - Exit; - - if NewStyleControls and (FBorderStyle = bsSingle) then - RecreateWnd{$IFDEF LCL}(self){$ENDIF}; - - inherited; -end; -{=====} - {$IFNDEF LCL} procedure TVpCustomNavBar.CMDesignHitTest(var Msg : TCMDesignHitTest); begin @@ -1193,7 +1176,7 @@ begin with Params do Style := LongInt(Style) or BorderStyles[FBorderStyle]; - if NewStyleControls and Ctl3D and (FBorderStyle = bsSingle) then begin + if NewStyleControls {and Ctl3D }and (FBorderStyle = bsSingle) then begin Params.Style := Params.Style and not WS_BORDER; Params.ExStyle := Params.ExStyle or WS_EX_CLIENTEDGE; end; diff --git a/components/tvplanit/source/vptasklist.pas b/components/tvplanit/source/vptasklist.pas index acd6f6a5e..fca1603e6 100644 --- a/components/tvplanit/source/vptasklist.pas +++ b/components/tvplanit/source/vptasklist.pas @@ -444,8 +444,6 @@ end; constructor TVpTLInPlaceEdit.Create(AOwner: TComponent); begin inherited Create(AOwner); - ParentCtl3D := False; - Ctl3D := False; TabStop := False; BorderStyle := bsNone; {$IFDEF VERSION4} diff --git a/components/tvplanit/source/vpweekview.pas b/components/tvplanit/source/vpweekview.pas index 7fb3ccc56..2dfe3fdca 100644 --- a/components/tvplanit/source/vpweekview.pas +++ b/components/tvplanit/source/vpweekview.pas @@ -301,8 +301,6 @@ uses constructor TVpWvInPlaceEdit.Create(AOwner: TComponent); begin inherited Create(AOwner); - ParentCtl3D := False; - Ctl3D := False; TabStop := False; BorderStyle := bsNone; {$IFDEF VERSION4}