Вниз
Скачать: CL | DM;

Worse, it is a general bug!   Найти похожие ветки 

 
thaddy   (2005-10-19 19:58) [0]

Vladimir,

My previous post hints to a far more serious issue:

The use of  GetThreadPriorityBoost break win9X compatibility!
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

I suggest:

 if (WinVer => WvNT) and (GetThreadPriorityBoost( fHandle, B )) then
   Result := B;


 
thaddy   (2005-10-19 20:03) [1]



function TThread.GetPriorityBoost: Boolean;
var B: Bool;
begin
 Result := TRUE;
 if fHandle = 0 then Exit;
 if (WinVer >= WvNT) and GetThreadPriorityBoost( fHandle, B ) then
   Result := B;
end;

procedure TThread.SetPriorityBoost(const Value: Boolean);
begin
 if fHandle = 0 then Exit;
 if (WinVer >= WvNT) and SetThreadPriorityBoost( fHandle, not Value );
end;


 
thaddy   (2005-10-19 20:06) [2]

Sorry, I have a flue:


function TThread.GetPriorityBoost: Boolean;
var B: Bool;
begin
 Result := TRUE;
 if fHandle = 0 then Exit;
 if (WinVer >= WvNT) then // only evaluate if this is true, regardless of evaluation settings
   if GetThreadPriorityBoost( fHandle, B ) then
     Result := B;
end;

procedure TThread.SetPriorityBoost(const Value: Boolean);
begin
 if fHandle = 0 then Exit;
 if WinVer >= WvNT then
     SetThreadPriorityBoost( fHandle, not Value );
end;



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.45 MB
Время: 0.026 c
15-1150116765
asdqwer
2006-06-12 16:52
2006.07.09
Исчез Интернет у компьютера в локальной сети


15-1149680139
космический дворецкий
2006-06-07 15:35
2006.07.09
Упражнения для развития артикуляции


2-1150877067
XTD
2006-06-21 12:04
2006.07.09
Управление приложениями с помощью DELPHI


3-1147407297
apl
2006-05-12 08:14
2006.07.09
Записи в таблице и даты создания файлов.


3-1147266021
Morrison
2006-05-10 17:00
2006.07.09
Index is read-only. Что делать?




   Наверх