Qt: TQtCaret is more responsive now, added high priority to postEvent() for OnWakeMainThread() and PostMessage().

git-svn-id: trunk@15957 -
This commit is contained in:
zeljko 2008-08-05 12:32:27 +00:00
parent e4a2bd9d92
commit 64d1536bb4
3 changed files with 10 additions and 4 deletions

View File

@ -374,12 +374,18 @@ end;
procedure TEmulatedCaret.Lock;
begin
EnterCriticalSection(FCritSect);
{$note TEmulatedCaret.Lock()
remove this routine later, after
testing on all platforms}
// EnterCriticalSection(FCritSect);
end;
procedure TEmulatedCaret.Unlock;
begin
LeaveCriticalSection(FCritSect);
{$note TEmulatedCaret.UnLock()
remove this routine later, after
testing on all platforms}
// LeaveCriticalSection(FCritSect);
end;
function TEmulatedCaret.CreateColorPixmap(Color: PtrUInt): QPixmapH;

View File

@ -356,7 +356,7 @@ var
Event: QEventH;
begin
Event := QEvent_create(LCLQt_CheckSynchronize);
QCoreApplication_postEvent(QCoreApplication_instance(), Event);
QCoreApplication_postEvent(QCoreApplication_instance(), Event, 1 {high priority});
end;
function TQtWidgetSet.LCLPlatform: TLCLPlatform;

View File

@ -3639,7 +3639,7 @@ begin
if Handle <> 0 then
begin
Event := QLCLMessageEvent_create(QEventLCLMessage, Msg, wParam, lParam, 0);
QCoreApplication_postEvent(Widget.Widget, Event);
QCoreApplication_postEvent(Widget.Widget, Event, 1 {high priority});
Result := True;
end;
end;