0 Members and 1 Guest are viewing this topic.
function KeyHook_open(){ KeyHook_hold = null; if (TASKER_TASK_LIST.name.indexOf("KeyHook")!=-1){ event_notify('Task already exists'); }else{ tasker_create_task('KeyHook','KeyHook_hook()',null,2); }}function KeyHook_hook(){ if ( keyboard_getKey(192) && KeyHook_hold == null ){ if (launcher.childNodes[1].style.visibility == 'hidden'){ desktop_launcher_open(); }else{ desktop_launcher_close(); } setTimeout('KeyHook_Off();',10); KeyHook_hold = 1; } }function KeyHook_Off(){ if(!keyboard_getKey(192)){ KeyHook_hold = null; }else{ setTimeout('KeyHook_Off();',100); } }
function file_rline(path,line){ file = file_read(path); lines = file.replace(/(\r\n|\r|\n)/g, '\n').split('\n'); return lines[line];}
function file_wline(path,line,content){ file = file_read(path); lines = file.replace(/(\r\n|\r|\n)/g, '\n').split('\n'); lines[line] = content; file = lines.join("\n"); file_create(path,file);}