Posted 09 October 2014 - 10:26 PM
http://pastebin.com/NqxztSnF
This is what i managed to create, but i have few problems.
Is there any better way to kill process than sending terminate? With pullEventRaw terminate can be avoided, and im mot sure if removing coroutine address from tProcesses table would actually make Lua's garbage collector delete it.
My "killProcess" function doesnt work, but im not sure why. I also had sendEvent functions but they all crashed when they reached 121 line. It looks that something is wrong with term.redirect but i dont have slightest idea what.
Things that changed from original multishell:
no tab row at top of the screen . im planning to create optional tabs manager on the first shell, but currently if you want to visit other tab than first you have to use multishell.setFocus
if you want to return to tab 1st you have to press "ctrl" and "alt" really fast :)/> it will work even if you have something running on current tab.
If i solve my problems mentioned above there will also be a way to send events directly from one tab to another and kill tabs at will. (sending events is implemented in normal event system but it doesnt work as it should)
I reduced number of coroutine.status checks. earlier it checked status each time you fired an event, and i think that was a bit overkill.
Now tabs have static ID's, and no process will receive already used ID, unless you restart computer/PDA.
Added few functions that can help managing opened tabs.
Any feedback & ideas would be appreciated.
This is what i managed to create, but i have few problems.
Is there any better way to kill process than sending terminate? With pullEventRaw terminate can be avoided, and im mot sure if removing coroutine address from tProcesses table would actually make Lua's garbage collector delete it.
My "killProcess" function doesnt work, but im not sure why. I also had sendEvent functions but they all crashed when they reached 121 line. It looks that something is wrong with term.redirect but i dont have slightest idea what.
Things that changed from original multishell:
no tab row at top of the screen . im planning to create optional tabs manager on the first shell, but currently if you want to visit other tab than first you have to use multishell.setFocus
if you want to return to tab 1st you have to press "ctrl" and "alt" really fast :)/> it will work even if you have something running on current tab.
If i solve my problems mentioned above there will also be a way to send events directly from one tab to another and kill tabs at will. (sending events is implemented in normal event system but it doesnt work as it should)
I reduced number of coroutine.status checks. earlier it checked status each time you fired an event, and i think that was a bit overkill.
Now tabs have static ID's, and no process will receive already used ID, unless you restart computer/PDA.
Added few functions that can help managing opened tabs.
Any feedback & ideas would be appreciated.
Edited on 09 October 2014 - 08:26 PM