HTMLv 0.93b: bug with 100% cpu loading in RmB menu fixed (thanks 0CodErr)

git-svn-id: svn://kolibrios.org@2799 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Kirill Lipatov (Leency) 2012-06-16 18:35:16 +00:00
parent 6684f99167
commit 7fafcb264e
2 changed files with 5 additions and 6 deletions

View File

@ -9,7 +9,7 @@ dword j,
char download_path[]="/rd/1/.download";
char search_path[]="http://nigma.ru/index.php?s=";
char version[]=" Text-based Browser 0.93";
char version[]=" Text-based Browser 0.93b";
char tinypad_path[]="/sys/tinypad";
char t_edit_path[]="/sys/develop/t_edit";

View File

@ -23,10 +23,13 @@ void menu_rmb()
SetEventMask(100111b);
loop() switch(CheckEvent())
loop() switch(WaitEvent())
{
case evMouse:
mm.get();
if (mm.lkm) || (mm.pkm)
if (mm.x>ITEM_WIDTH) || (mm.y>items_num*ITEM_HEIGHT+1) ExitProcess();
id=mm.y/ITEM_HEIGHT;
if (id<0) || (id+1>items_num) break;
if (items_cur<>id)
@ -84,9 +87,5 @@ void menu_rmb()
DrawBar(1, i*ITEM_HEIGHT+1, ITEM_WIDTH-1, ITEM_HEIGHT, EDX);
WriteText(8,i*ITEM_HEIGHT+6,0x80,0x000000,ITEMS_LIST[i],0);
}
default:
GetProcessInfo(#MenuForm, SelfInfo);
id=GetSlot(MenuForm.ID);
if (id<>ActiveProcess()) ExitProcess();
}
}