mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-12 00:20:08 +02:00
* Fixed TStatusBar regressions under linux (not visible) introduced by latest patches.
git-svn-id: trunk@11583 -
This commit is contained in:
parent
55f077b595
commit
a963094291
@ -54,6 +54,7 @@ type
|
|||||||
class procedure Update(const AStatusBar: TStatusBar); override;
|
class procedure Update(const AStatusBar: TStatusBar); override;
|
||||||
class procedure GetPreferredSize(const AWinControl: TWinControl;
|
class procedure GetPreferredSize(const AWinControl: TWinControl;
|
||||||
var PreferredWidth, PreferredHeight: integer; WithThemeSpace: Boolean); override;
|
var PreferredWidth, PreferredHeight: integer; WithThemeSpace: Boolean); override;
|
||||||
|
class procedure AddControl(const AControl: TControl); override;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ TQtWSTabSheet }
|
{ TQtWSTabSheet }
|
||||||
@ -528,15 +529,6 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{some systems doesn't show statusbar inside mainwindow
|
|
||||||
(linux tested on FC3,FC4,FC7 ).}
|
|
||||||
{$ifdef linux}
|
|
||||||
if Assigned(AWinControl.Parent)
|
|
||||||
and (AWinControl.Parent.Handle = Application.MainForm.Handle)
|
|
||||||
then
|
|
||||||
QMainWindow_setStatusBar(QMainWindowH(TQtMainWindow(AWinControl.Parent.Handle).Widget), QStatusBarH(QtStatusBar.Widget));
|
|
||||||
{$endif}
|
|
||||||
|
|
||||||
// Return handle
|
// Return handle
|
||||||
|
|
||||||
Result := THandle(QtStatusBar);
|
Result := THandle(QtStatusBar);
|
||||||
@ -707,6 +699,25 @@ begin
|
|||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
class procedure TQtWSStatusBar.AddControl(const AControl: TControl);
|
||||||
|
var
|
||||||
|
QtStatusBar: TQtStatusBar;
|
||||||
|
begin
|
||||||
|
inherited AddControl(AControl);
|
||||||
|
|
||||||
|
{some systems doesn't show statusbar inside mainwindow
|
||||||
|
(linux tested on FC3,FC4,FC7,Ubuntu 7.04 ).}
|
||||||
|
{$ifdef linux}
|
||||||
|
if Assigned(AControl.Parent)
|
||||||
|
and (AControl.Parent.Handle = Application.MainForm.Handle)
|
||||||
|
then
|
||||||
|
begin
|
||||||
|
QtStatusBar := TQtStatusBar(TWinControl(AControl).Handle);
|
||||||
|
QMainWindow_setStatusBar(QMainWindowH(TQtMainWindow(AControl.Parent.Handle).Widget), QStatusBarH(QtStatusBar.Widget));
|
||||||
|
end;
|
||||||
|
{$endif}
|
||||||
|
end;
|
||||||
|
|
||||||
{ TQtWSCustomListView }
|
{ TQtWSCustomListView }
|
||||||
|
|
||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user