mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-20 16:41:19 +02:00
Merged revision(s) 63897 #a3272084cf, 63902 #6c19136b97, 63926 #317b7088a4, 63939 #6fddd1aaf4 from trunk:
LCL-GTK2: Improve setting a shaped form. Issue #30385, patch from Anton Kavalenka. ........ LCL-GTK2: Initialize a record in LCLIntfCellRenderer_CellDataFunc. Prevents a crash. Issue #37781, patch from Cyrax. ........ LCL: Fix ofAutoPreview of TOpenPictureDialog. Issue #37820, patch from Anton Kavalenka. ........ IDE: Fix a crash if IDE is aborted before updating configuration. ........ git-svn-id: branches/fixes_2_0@64610 -
This commit is contained in:
parent
9b78caaf21
commit
7c386df181
@ -1638,8 +1638,9 @@ end;
|
|||||||
destructor TMainIDE.Destroy;
|
destructor TMainIDE.Destroy;
|
||||||
begin
|
begin
|
||||||
ToolStatus:=itExiting;
|
ToolStatus:=itExiting;
|
||||||
|
// IDECommandList may be Nil if the IDE is aborted before updating configuration.
|
||||||
IDECommandList.RemoveCustomUpdateEvent(@UpdateMainIDECommands);
|
if Assigned(IDECommandList) then
|
||||||
|
IDECommandList.RemoveCustomUpdateEvent(@UpdateMainIDECommands);
|
||||||
|
|
||||||
if Assigned(ExternalTools) then
|
if Assigned(ExternalTools) then
|
||||||
ExternalTools.TerminateAll;
|
ExternalTools.TerminateAll;
|
||||||
|
@ -50,6 +50,7 @@ type
|
|||||||
TPreviewFileDialog = class(TOpenDialog)
|
TPreviewFileDialog = class(TOpenDialog)
|
||||||
private
|
private
|
||||||
FPreviewFileControl: TPreviewFileControl;
|
FPreviewFileControl: TPreviewFileControl;
|
||||||
|
function GetPreviewFileControl:TPreviewFileControl;
|
||||||
protected
|
protected
|
||||||
class procedure WSRegisterClass; override;
|
class procedure WSRegisterClass; override;
|
||||||
procedure CreatePreviewControl; virtual;
|
procedure CreatePreviewControl; virtual;
|
||||||
@ -57,7 +58,7 @@ type
|
|||||||
function DoExecute: boolean; override;
|
function DoExecute: boolean; override;
|
||||||
public
|
public
|
||||||
constructor Create(TheOwner: TComponent); override;
|
constructor Create(TheOwner: TComponent); override;
|
||||||
property PreviewFileControl: TPreviewFileControl read FPreviewFileControl;
|
property PreviewFileControl: TPreviewFileControl read GetPreviewFileControl;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ TOpenPictureDialog }
|
{ TOpenPictureDialog }
|
||||||
@ -275,6 +276,13 @@ end;
|
|||||||
|
|
||||||
{ TPreviewFileDialog }
|
{ TPreviewFileDialog }
|
||||||
|
|
||||||
|
function TPreviewFileDialog.GetPreviewFileControl: TPreviewFileControl;
|
||||||
|
begin
|
||||||
|
if not Assigned(fPreviewFileControl) then
|
||||||
|
Self.CreatePreviewControl;
|
||||||
|
Result:=fPreviewFileControl;
|
||||||
|
end;
|
||||||
|
|
||||||
class procedure TPreviewFileDialog.WSRegisterClass;
|
class procedure TPreviewFileDialog.WSRegisterClass;
|
||||||
begin
|
begin
|
||||||
inherited WSRegisterClass;
|
inherited WSRegisterClass;
|
||||||
|
@ -425,6 +425,7 @@ var
|
|||||||
ListItem: TListItem;
|
ListItem: TListItem;
|
||||||
Value: TGValue;
|
Value: TGValue;
|
||||||
begin
|
begin
|
||||||
|
FillByte(Value{%H-},SizeOf(Value),0);
|
||||||
if G_IS_OBJECT(cell) = false then
|
if G_IS_OBJECT(cell) = false then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
|
@ -4112,6 +4112,7 @@ function GetControlWindow(Widget: Pointer) : PGDKWindow;
|
|||||||
begin
|
begin
|
||||||
if Widget <> nil then
|
if Widget <> nil then
|
||||||
begin
|
begin
|
||||||
|
gtk_widget_realize(Widget); // associate with window
|
||||||
If not GTKWidgetIsA(PGTKWidget(Widget), GTK_Layout_Get_Type) then
|
If not GTKWidgetIsA(PGTKWidget(Widget), GTK_Layout_Get_Type) then
|
||||||
Result := PGTKWidget(Widget)^.Window
|
Result := PGTKWidget(Widget)^.Window
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user