Qt: removed usage of slow QApplication_syncX() when showing forms, all X11 code merged into one ifdef inside ShowHide().

git-svn-id: trunk@34051 -
This commit is contained in:
zeljko 2011-12-08 17:16:47 +00:00
parent cbd0b3eabe
commit f0cd76b3a5

View File

@ -476,23 +476,28 @@ begin
{$IFDEF HASX11} {$IFDEF HASX11}
if AWinControl.HandleObjectShouldBeVisible and if AWinControl.HandleObjectShouldBeVisible and
(fsModal in TForm(AWinControl).FormState) then not (csDesigning in TForm(AWinControl).ComponentState) and
(TForm(AWinControl).FormStyle <> fsMDIChild) then
begin begin
if (Application.TaskBarBehavior <> tbSingleButton) then if (fsModal in TForm(AWinControl).FormState) then
begin begin
SetSkipX11Taskbar(Widget.Widget, True); if (Application.TaskBarBehavior <> tbSingleButton) then
Widget.setShowInTaskBar(False); begin
SetSkipX11Taskbar(Widget.Widget, True);
Widget.setShowInTaskBar(False);
end;
if (QtWidgetSet.WindowManagerName = 'metacity') then
X11Raise(QWidget_winID(Widget.Widget));
end else
if (TForm(AWinControl).FormStyle = fsSplash) then
begin
//process only qt sys events
QCoreApplication_processEvents(QEventLoopExcludeUserInputEvents);
//now send repaint to splash form
QWidget_repaint(Widget.Widget);
end; end;
if (QtWidgetSet.WindowManagerName = 'metacity') then
X11Raise(QWidget_winID(Widget.Widget));
end; end;
{$ENDIF} {$ENDIF}
{$IFDEF HASX11}
if (QtVersionMajor = 4) and (QtVersionMinor >= 6)
and (TForm(AWinControl).FormStyle <> fsMDIChild) then
QApplication_syncX();
{$ENDIF}
end; end;
{------------------------------------------------------------------------------ {------------------------------------------------------------------------------