mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-27 11:00:37 +02:00
Gtk2: revert TGtk2WidgetSet.FinishCreateHandle() since it's used by opengl implementation. issue #21569
git-svn-id: trunk@36347 -
This commit is contained in:
parent
dbf6d2c8f6
commit
861c143774
@ -258,6 +258,9 @@ type
|
|||||||
function DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor; override;
|
function DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor; override;
|
||||||
procedure DCSetPixel(CanvasHandle: HDC; X, Y: integer; AColor: TGraphicsColor); override;
|
procedure DCSetPixel(CanvasHandle: HDC; X, Y: integer; AColor: TGraphicsColor); override;
|
||||||
procedure DCRedraw(CanvasHandle: HDC); override;
|
procedure DCRedraw(CanvasHandle: HDC); override;
|
||||||
|
{used by 3rd party components eg. opengl implementation}
|
||||||
|
procedure FinishCreateHandle(const AWinControl: TWinControl;
|
||||||
|
Widget: PGtkWidget; const AParams: TCreateParams);
|
||||||
|
|
||||||
private
|
private
|
||||||
{$IFDEF HASX}
|
{$IFDEF HASX}
|
||||||
|
@ -4509,6 +4509,29 @@ begin
|
|||||||
LastRight:=EmptyLastMouseClick;
|
LastRight:=EmptyLastMouseClick;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TGtk2WidgetSet.FinishCreateHandle(const AWinControl: TWinControl;
|
||||||
|
Widget: PGtkWidget; const AParams: TCreateParams);
|
||||||
|
var
|
||||||
|
WidgetInfo: PWidgetInfo;
|
||||||
|
Allocation: TGTKAllocation;
|
||||||
|
begin
|
||||||
|
WidgetInfo := GetWidgetInfo(Widget,true); // Widget info already created in CreateAPIWidget
|
||||||
|
WidgetInfo^.LCLObject := AWinControl;
|
||||||
|
WidgetInfo^.Style := AParams.Style;
|
||||||
|
WidgetInfo^.ExStyle := AParams.ExStyle;
|
||||||
|
WidgetInfo^.WndProc := PtrUInt(AParams.WindowClass.lpfnWndProc);
|
||||||
|
|
||||||
|
// set allocation
|
||||||
|
Allocation.X := AParams.X;
|
||||||
|
Allocation.Y := AParams.Y;
|
||||||
|
Allocation.Width := AParams.Width;
|
||||||
|
Allocation.Height := AParams.Height;
|
||||||
|
gtk_widget_size_allocate(Widget, @Allocation);
|
||||||
|
|
||||||
|
Set_RC_Name(AWinControl, Widget);
|
||||||
|
TGtk2WSWinControl.SetCallbacks(PGtkObject(Widget), AWinControl);
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TGtk2WidgetSet.DestroyConnectedWidget(Widget: PGtkWidget;
|
procedure TGtk2WidgetSet.DestroyConnectedWidget(Widget: PGtkWidget;
|
||||||
CheckIfDestroying: boolean);
|
CheckIfDestroying: boolean);
|
||||||
var
|
var
|
||||||
|
Loading…
Reference in New Issue
Block a user