Omnimaga

General Discussion => Technology and Development => Web Programming and Design => Topic started by: Eeems on June 12, 2010, 02:40:25 am

Title: jBasic OS
Post by: Eeems on June 12, 2010, 02:40:25 am
jBasic OS is a branch off of mine from the jBasic project (link (http://ourl.ca/4702)) but its a complete re-write, and a completely different project entirely, but it was inspires by jBasic.
jBasic OS is going to be a web OS with tasks, windows, custom cursors and more. Its kind of like EyeOS, but different. jBasicOS will have a desktop client (using xulrunner) and can be run off of a web server if anybody is so inclined to set one up :p
The desktop client will have little or no xul interface, it will most likely be just a window open to an html document.
Making applications for it will be easy i hope, I will have commands for creating windows, interfacing with them, moving them. I will also have commands for interfacing with the mouse. Tasks can be cancelled by a task manager, i will have a system speed variable (framerate) to let you know how much of a slowdown you are undergoing due to open applications. Applications will be required to name their functions starting with the application name, then an underscore so they can interface with the system without messing things up.
Currently I ony have the ideas in my head, and the basic headers on my files, so wish me luck, I'll post updates as I go.
If anybody wants to help me with the project, please let me know, hopefully we can work together on it :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 12, 2010, 02:42:34 am
Mhmm this seems interesting. Any screenshot so far?

Btw you didn't quit calc programming, don't you? You haven't worked on anyhting since March :(
Title: Re: jBasic OS
Post by: Eeems on June 12, 2010, 02:49:17 am
No, I havent gotten far enough.
No, i just havent had much time, and i have a cool project i want to do with builderboy, i just keep forgetting to ask him x.x summer is almost here though so i will have more time.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 12, 2010, 02:56:08 am
Aaah ok, I got kinda worried x.x
Title: Re: jBasic OS
Post by: calcdude84se on June 12, 2010, 09:35:34 am
Sounds cool. I'll be more interested once it's out of your head and in javascript, though :P
Have fun!
Title: Re: jBasic OS
Post by: Eeems on June 12, 2010, 03:13:56 pm
ok, here is just a little test showing off me building windows, keep in mind this is very very early on.
http://future_history.freehostia.com/jBOS/Desktop.html

Also I would really appreciate some help on this project...mainly if someone would like to help with the css styling....

---merged by Eeems---

Sorry about the doublepost, but look now! you can move windows by dragging their titlebar! don't know if it works on anything other then firefox though.
Title: Re: jBasic OS
Post by: calcdude84se on June 12, 2010, 04:20:14 pm
I verify that it works in chrome... check!
If any browser has trouble, it'll probably be IE :P
Title: Re: jBasic OS
Post by: ztrumpet on June 12, 2010, 04:22:48 pm
Eeems, do you get your calc back for summer?  I hope you'll be able to use it soon. :)
Title: Re: jBasic OS
Post by: Eeems on June 12, 2010, 04:34:00 pm
No, I'm getting stuck with the 83+.... My little sister is getting the 84+...:/
I do have a computer now, so I can develop with wabbit and such...although it would be better if I had wabbit on my linux side :(

YAY! it works in chrome! IE will probably have trouble for sure....oh well, it's going to be xulrunner based, so I don't really have to worry.

---merged by Eeems---

Sorry again about the doublepost, just a major announcement again though
you can resize now by draggin the box on the bottom corner!
Title: Re: jBasic OS
Post by: willrandship on June 12, 2010, 06:20:34 pm
hmm...looks cool. So, will it support a mini-browser of sorts? That would be cool; Have a homepage that runs all your programs and various web pages. It just might make chromium OS bearable for me!

Good luck with your OS/Page/Thing.
Title: Re: jBasic OS
Post by: jnesselr on June 12, 2010, 06:31:49 pm
Oh yeah, IE gives problems.  Umm... It looks as if e.button is null.  In the mouse.js that is.
Title: Re: jBasic OS
Post by: calcdude84se on June 12, 2010, 06:40:21 pm
Nice, resizable. My only complaint is that window 2 is stuck above window 1. (Hopefully this shouldn't be too hard to change)
Keep up the good work!
Title: Re: jBasic OS
Post by: Eeems on June 12, 2010, 07:42:02 pm
Thanks all :)
grphmaster: umm...hmmm, which line was that on?
willrandship: actually I intend to make this standalone, but powered by xulrunner, but yes, I will allow for an online version :) It will support a mini browser of sorts, but someone will have to code it, or I could, when I'm done....if someone was to post the code for one (has to have all it's javascript in it right now prefixed with "<name of thing>_" for the functions.) I would be happy to include it :) make sure it has tabs though :P I love tabs :P
I'm thining about how to install new applications for it...I most likely will have to have them in a file and then javascript will set it up according to a folder setup...so like you would make a zip with this folder setup:
Code: [Select]
Javascript/
Images/
Css/
<app name>.js
and then you would change the .zip extension to something else...not sure what yet.
calcdude84se: yes I know about that, I will try to figure out how to solve that later...

anybody want to hear about my tasker setup? :D

EDIT: I just added close buttons and minimize buttons, minimize just makes it so only the title is seen or the window is 200x200

---merged by Eeems---

sorry about the doublepost but I just made it so that the active window is on top :P yay!
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 12, 2010, 11:49:34 pm
Nice :D, It's kinda old skool too ^^
Title: Re: jBasic OS
Post by: Eeems on June 13, 2010, 01:05:11 am
It's oldschool for now, I need someone to make a nicer stylesheet for me soon....
also, you can see the active task list now :D
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 13, 2010, 01:59:57 am
Try to not make it too graphic intensive, though, so it runs fine on older computers too :)
Title: Re: jBasic OS
Post by: Eeems on June 13, 2010, 02:33:37 am
Well, it will work on top of the line single cores for sure, since i am developing it on there. I dont think it will be too intensive, unless you try to run my physics engine with >100 objects and object collision turned on :p
An update: i have a task manager started, all it does now is list tasks, later i will add the ablility to stop all none system tasks from it. Stopping windows and their tasks work with the close button. For developers to make their apps scrollable they will have to put the scrollable content in a new div because the body div will not have scrolling due to rendering issues. I made a clock and a fps counter. The system will update a clock variable that developers can use so they dont have to burden th system with their own timers and clocks. They can use the system fps variable as well because the system updates that as well. Tomorrow I will work on making that Tasker change the intervals on none priorety apps when the fps drops too low. Wish me luck, also, i just got older :D
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 13, 2010, 02:48:49 am
Nice ^^
Title: Re: jBasic OS
Post by: Eeems on June 13, 2010, 06:38:33 pm
Ok I've made an actual Task Manager, and the Tasker will now help decrease CPU load by increasing the time between tasks that are not system tasks if the FPS goes below 20fps. It will then display an alert on top of all the windows. I'm pretty impressed with it myself :P
Title: Re: jBasic OS
Post by: calcdude84se on June 13, 2010, 06:39:22 pm
Nice... I'll try it out now.
Title: Re: jBasic OS
Post by: Eeems on June 14, 2010, 12:26:47 am
ok, changed the alert to an notification event that I made, it will alert on the desktop and dissapear after 10 seconds. when your FPS gets back to acceptable it will then alert you on how many passes it took to reset it.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 14, 2010, 12:39:27 am
Nice. I can't test it now, though, I think, right? (I am on a quad core computer with 8 GB of RAM :P)
Title: Re: jBasic OS
Post by: Eeems on June 14, 2010, 01:44:19 am
Lol, yes you can, just overload the system with the jBasic Physics engine app, although I don't know if I actually uploaded this version.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 14, 2010, 02:06:45 am
oh right I forgot about that one x.x

I'll try now.
Title: Re: jBasic OS
Post by: Eeems on June 14, 2010, 09:51:16 am
Ok, I uploaded it now. I am working on making it show above all the windows, but it hasnt worked yet. I think i know the problem though.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 14, 2010, 01:05:37 pm
Nice I like how the notificiations appears on top-right now
Title: Re: jBasic OS
Post by: Eeems on June 14, 2010, 04:18:04 pm
Yeah I intended for it to do that, I can't seem to get it to display on top of everything though, I'll hopefully figure it out today...stupid z-index....
Title: Re: jBasic OS
Post by: willrandship on June 14, 2010, 04:45:09 pm
Hmm...One thing I think it should have soon is a taskbar, or some other way of opening the tasks you have now. I found myself with a black screen last time, because I closed everything.
Title: Re: jBasic OS
Post by: Eeems on June 14, 2010, 04:52:07 pm
Yeah I plan on developing the desktop more later today, I plan on adding in a app launcher and a taskbar on the top.
Should I make the taskbar like the topbar on a mac? or more like the windows one?
Title: Re: jBasic OS
Post by: willrandship on June 14, 2010, 04:56:57 pm
Well, it doesn't matter too much to me. I've used both top and bottom bars, and I must say, for me at least, it makes little difference.

Hmm, I just had a cool idea. Run this from a terminal in linux, after killing Gnome. You have a lightweight, java based Desktop Environment! Can java run outside of a window manager?

Edit: Hey....check this out! http://lobobrowser.org/java-browser.jsp (http://lobobrowser.org/java-browser.jsp)
That might make a good browser for you!
Title: Re: jBasic OS
Post by: Eeems on June 14, 2010, 05:04:48 pm
This is Javascript, but yes, that could work...I just have to do a lot of work on the filesystem stuff next.
For my portable browser I was thinking of just making an iframe to the Firefox.xul, so I would have to include it with the system...
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 14, 2010, 11:35:50 pm
Just don't add a dock like on Mac. I hate that. It always gets in the way when I move my mouse at the bottom of screen trying to click stuff somewhere else like a webpage
Title: Re: jBasic OS
Post by: Eeems on June 14, 2010, 11:57:03 pm
yeah I'm not going to add a dock x.x I was thinking about the topbar, but that could be a hassle...I think I'll stick with a windows like one, just no active windows...or I could...it's possible to test if a process has a window...
Title: Re: jBasic OS
Post by: Eeems on June 15, 2010, 05:17:28 pm
Ok, so I have completed dynamic booting, now to add in loading of apps and such, as well as work on the desktop a bit...so yeah, It wont work online anymore, I'll have to release the source and to load it you need firefox (don't know if it works anymore on anything else) and you will just open boot.html :) right now it loads all the system libraries and then runs all their processes...I'll add in loading in apps but not running them next. Attached is the source. I can't seem to make it a .zip though for some reason, so someone will have to extract it and zip it for me then...it's a .tar.gz btw...
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 15, 2010, 05:43:28 pm
How do I run that file? I hope you eventually plan to release executables if it's just the source, since we don't like to have to manually compile stuff ourselves when we get softwares.
Title: Re: jBasic OS
Post by: Eeems on June 15, 2010, 06:39:41 pm
Well I plan on making a xulrunner application for this so you don't need firfox, just xulrunner and it will install icons and everything with it. right now you just open boot.html to run it, but all it does is load, so yeah, nothing is actually running but the system background tasks. this reminds me, I need to set up the keyboard 'drivers' so you can integrate with keypress
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 15, 2010, 06:54:33 pm
and where can I find boot.html? In the tar file, all there is is a file called jBOS with no extension.
Title: Re: jBasic OS
Post by: Eeems on June 15, 2010, 09:55:31 pm
that's a directory, inside that is the files.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 15, 2010, 09:57:01 pm
No, I opened the tar file and inside, saw the jBOS file with a "unknown file type" icon. When I double-click it, it asks me with what program I want to open jBOS with. Your tar file might be corrupted or not Winrar/Windows compatible

EDIT: Screenshot
Title: Re: jBasic OS
Post by: Eeems on June 15, 2010, 11:31:11 pm
Hmm, strange...well it is a directory, so someone with more windows knowledge then me will have to help on this...
I did some initial work with xulrunner, and it seems that that is not going to work...but I will continue to support firefox so don't worry.
Currently it will only load all the files in the js/ directory as well as run their initalizing scripts. it will also load the style, and the path to the style can be set in boot/dirs.js in case you want to make your own and send it to me :P apps currently are put in apps/appname.app/ with this folder structure
Code: [Select]
appname.app
|-- js
|--css
|--img
|--appname.js
js is for javascript of course, so any javascript libraries would be put here, css is for css stylesheets, img is for images and appname.js is where the actual application is.

I am currently working on adding app loading and the desktop.
also I added a system task called '#SYSTEM DESKTOP CLEANER' that cleans up all content outside of the desktop in the <body> because it is not displayed.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 15, 2010, 11:36:06 pm
I see. Do you think the software you use to compress the tar file might be at fault?
Title: Re: jBasic OS
Post by: Tribal on June 16, 2010, 12:04:37 am
Repackaged as a zip for all those under windows. Not sure exactly why WinRAR was having problems with it though  :-\
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 16, 2010, 12:50:22 am
Ok I downloaded that one and unzipped. However, is it supposed to display a black screen on Firefox? It doesn't do anything else.
Title: Re: jBasic OS
Post by: Eeems on June 16, 2010, 01:53:56 am
Did it prompt you or anything? Do you have firebug installed? That would help me know what happened.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 16, 2010, 01:55:16 am
Oh, it didn't prompt me anything and no I don't have firebug installed since I normally never use Firefox. Is it available on their site or in the extensions?

EDIT: Wait do you just mean the warning about potential malicious scripts?

Quote
Un script provenant de « file:// » demande des fonctionnalités avancées qui sont NON SÛRES et susceptibles d'être utilisées pour compromettre votre machine ou vos données :

Exécuter ou installer des logiciels sur votre machine


Il n'est conseillé d'autoriser ces fonctionnalités que si leur provenance est connue pour être exempte de virus ou de programmes malicieux.
Title: Re: jBasic OS
Post by: Eeems on June 16, 2010, 02:27:34 am
Yes that, that is needed so it can read the files, allow it.
Firebug is available on Mozilla addon site actually, so tools>addons and type into the searchbar firebug
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 16, 2010, 02:29:44 am
Ok so I got Firebug. Now what do I need to do?
Title: Re: jBasic OS
Post by: Eeems on June 16, 2010, 01:41:05 pm
After talking to DJ on SAX I have determined that the version I released will not work on windows yet, and it will take a little editing to work on linux, so I'll release the most recent version later today, hopefully with Windows support.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 16, 2010, 02:16:47 pm
Ok, I wish you good luck. I hope you can eventually make it cross platform compatible
Title: Re: jBasic OS
Post by: Eeems on June 16, 2010, 08:06:44 pm
yeah it shouldn't be too hard to solve, I had ADE working after all.

EDIT: oh yeah I forgot, I added Keyboard support in the same way as jBasic, but with a different command name due to the rules I have put in place for function nameing it's keyboard_getkey(#);
Title: Re: jBasic OS
Post by: Eeems on June 16, 2010, 09:39:36 pm
Sorry about the doublepost

ok, here is the topbar so far, with the app launcher loaded, but I haven't made the script to populate it yet. So yeah, what do you think?
Also anybody want to make a nicer style for me? :P

EDIT: ok, applications run now! :D
take a look at the screenshot

EDIT2: new version, I'm unsure if this fixes the windows bug, but we can test it. I also got .zip to work :D
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 17, 2010, 12:33:28 am
Well  still a black page in Firefox, but to comment on those screenshots that looks quite nice. I like the style, except maybe the circle buttons should be a bit smaller and the text a bit smaller too
Title: Re: jBasic OS
Post by: Eeems on June 17, 2010, 12:39:56 am
Ok, I am working on the windows issue, that should be solved by tomorrow.

EDIT: or by tonight, someone try this one
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 17, 2010, 03:20:19 am
still black page :S
Title: Re: jBasic OS
Post by: Eeems on June 17, 2010, 09:36:41 am
Ok, new version with support for multiple windows correctly implemented :D
Title: Re: jBasic OS
Post by: Eeems on June 18, 2010, 06:34:28 pm
Ok, I have a windows copy that works, and the command app works, although it could use some work. Have fun :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 18, 2010, 06:41:52 pm
yay it seems to work! Well at least in Firefox it does, so that's a start ^^
Title: Re: jBasic OS
Post by: Eeems on June 18, 2010, 06:44:51 pm
Yay!
well, it's kind of limited to firefox for now, because I have to use firefox specific commands to make it work.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 18, 2010, 06:46:18 pm
Yeah I know. I am curious if in future versions it will be possible to have compatibility with all browsers?
Title: Re: jBasic OS
Post by: Eeems on June 19, 2010, 10:52:06 am
Well I might with some, but it all depends on if they have ways to do what I want them to do (ie: reading local folders/files, manipulating local folders/files).
Wow, I'm starting to end my lines with semi-colons now x.x way too much javascript for me x.x
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 19, 2010, 11:01:53 am
LOL XD

I guess this is the side effect of being programmers ;D
Title: Re: jBasic OS
Post by: Eeems on June 19, 2010, 11:11:39 am
yeah x.x
well...it's not the first time even actually x.x
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 19, 2010, 11:24:04 am
Well... your post made me start a thread in Randomness for sure, though. :P

I hope you don't accidentally use ClrHome to clear the browser window at least :P
Title: Re: jBasic OS
Post by: Eeems on June 19, 2010, 06:26:35 pm
lol, no I just type in clear for that :P j/k
so, anybody want to start developing apps, for this? I can work up some documentation of you want :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 19, 2010, 06:28:23 pm
mhmm I'M not too sure yet since I have an hard time learning stuff lately x.x. Maybe later after my vacations when my mind is cleaner or something.
Title: Re: jBasic OS
Post by: Eeems on June 19, 2010, 06:38:49 pm
That would be cool :)
yeah I should probably jump on that documentation, as well as make things easier for you to interface with stuff... I should also include some sort of thing that allows you to run certain commands on the quitting of a window,
Title: Re: jBasic OS
Post by: Eeems on June 20, 2010, 09:43:57 pm
All that I've changed in this version is the addition of the file commands file_cd() file_create() and file_delete(). All of which can only be used by developers right now (unless you use the command app). These commands work on both Windows and Linux :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 20, 2010, 10:00:01 pm
aaah ok cool ^^

Nice to see some progress
Title: Re: jBasic OS
Post by: Eeems on June 20, 2010, 10:04:39 pm
Yeah I'm planning to make enough for Kerm Martian to make a file browser :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 20, 2010, 10:05:14 pm
oooh he wants to do that? It would be nice ^^
Title: Re: jBasic OS
Post by: Eeems on June 20, 2010, 10:14:15 pm
Yeah I asked him to :)
Title: Re: jBasic OS
Post by: _player1537 on June 20, 2010, 11:12:06 pm
ooh this is awesome!  How will I develop for this?  (didn't read the thread fully)  the only thing I found wierd was when I tried to resize windows, it freaks out sometimes and doesn't recognize that I let go of the mouse button.  Other than that, good job!  Can't wait to see more progress
Title: Re: jBasic OS
Post by: Eeems on June 20, 2010, 11:42:34 pm
Thanks! To develop for this you need a moderate understanding of Javascript. I have commands for interfacing with the GUI already built in so it shouldn't be too hard to make wibdows and such.
Apps are all in the apps folder and have to be in this structure
Code: [Select]
<appname>
|- js/
|- css/
|- img/
|- other/
|- <appname>.js
|- icon.png (not implmented yet)
your <appname>.js must have a functuon named <appname>_open() which opens the app and all the functions must be prefixed with <appname>_ so multiple apps don't overwrite other apps functions. There are lots of built in functions which i should document for you, but i havent taken the time yet. If anybody wants to port over libraries that would be nice.
The resize error is due to the content of the window, i have an idea on how to fix it though, but I havent imolemented it yet.
Title: Re: jBasic OS
Post by: _player1537 on June 20, 2010, 11:47:43 pm
ok, I went through the source of all the apps.  I understand the main thing on how to make the windows...its the other stuff I get lost at.  I don't really understand JS sadly...so I might be slow at understanding that, but the basic concept I am getting.  I might go and look for a JS tutorial to see if I get it any better, but idk I might finally get it if I see working code in action with JS.  Looking forward to a tutorial for someone (almost) completely programming illiterate ;)
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 12:01:18 am
ah ok, well some good tutorials would be on W3 Schools (http://w3schools.com) and for firefox specific stuff which you will probably want to know if you want to do some cooler stuff with the filesystem go to Mozilla MDC (https://developer.mozilla.org). For making apps you will want to play around a lot will accessing and changing stuff with javascript.
Hopefully I can get some documentation done later this week (after exams). For your first app you might want to work on something simple, like maybe a popup/alert invoker (takes the text you input and alerts with it). Then you might want to go farther, and maybe even play around with tasks and stuff.
Title: Re: jBasic OS
Post by: willrandship on June 21, 2010, 12:13:56 am
Lol, I'm posting this from in jbasic OS, through the google browser.

Any chance at a URL Bar for that? Also, When I made the Browser large enough to use, the bar got cut in half, so only the bottom half of "Google Browser" and the circles are visible

I noticed that This browser has Flash support :P Is that cause it's running in firefox with flash enabled?

Edit: Hang on, now the whole window bar is gone.
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 12:16:19 am
I tried messing with the code to add that...didn't get it to work though x.x

Edit:
W00T!!
got some code to work :P  it makes a window, and whenever you click the button on it it creates another window with another button (the new one doesn't do anything).  How do I use random numbers in JS?

Here is my code:
Code: [Select]
function AB_open(){
window_create('BUTTONZ','','',100,100,"<input type='button' onclick='AB_Windowz()'></input>");
}
function AB_Windowz(){
window_create('BUTTONZ 2','','',100,100,"<input type='button'></input>");
}
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 01:05:24 am
Willrandship could you post a screenshot?
Player: try changing it to onlick="AB_open()" :p (yes i have support for multiple windows supoorted :))
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 01:06:58 am
yeah, I decided against doing that mainly because I am going to throw in alerting later. :)  also I made 30 BUTTONZ 2 windows XD
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 01:10:46 am
Ah ok :) question, do you know how to create tasks yet? You should try playing around with that.
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 01:11:35 am
nope, also I am trying to find your original JBasic file, I need the random command from it x.x

Edit: found it
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 01:15:41 am
Ah k. Well. I should document it for you.
Lol, yeah, there are a few commands i need to add to the extended functions list. I will add that later, thanks for reminding me :)

Btw, with tasks you can make intterupts for keypresses :D so like it alert for certain keys that are down and such. :)
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 01:20:02 am
ooh, what is this task code called, only the function and arguments, and a basic understanding of how the tasks work should be fine for now :)
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 01:25:49 am
Well, i cant remember for sure, but i thibk it was tasker_task_create() or something. Look in Tasks.js in js/ it should be there, along with the arguements.

All the tasker does is schedule intervals between what you want run. And in the case of low fps it increases the intervals.
You will have to figure out how to end a task wjen a window quits on your own for now. I have yet to add a onclose() function of any sort.
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 01:38:53 am
here is some code that doesn't seem to be working... can you help?
Code: [Select]
function AB_open(){
tasker_create_task('#THE GAME',AB_Windowz(),null,1000);
// window_create('BUTTONZ','','',100,100,"<input type='button' onclick='AB_Windowz()'></input>");
}
function AB_Windowz(){
if (keyboard_getkey(13)){
window_create('BUTTONZ 2','','',randomInt(100,300),randomInt(100,300),"<input type='button'></input>");
}
// event_notify('The Game');

}

//returns a random integer between a and b
function randomInt(a,b) {
 if (a < 0) {
  b = (b*2)+1;
 }
 return (Math.floor(Math.random()*b)+a)
}


Edit:  W00T, it works.  The error was the function is called "keyboard_getKey" not "keyboard_getkey" (K is capitalized)  also, around the function name at the top "tasker_create_task('#THE GAME',AB_Windowz(),null,1000);"  needs to be "tasker_create_task('#THE GAME','AB_Windowz()',null,1000);"  (quotes around AB_Windowz()  )
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 11:06:20 am
Yay!
have you come up with any ideas for a full app yet? I'll try to add in a onquit() of somesort soon that you can use.
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 11:11:15 am
not sure yet... I'd like to do a game of some sort, or a browser with favorites and all that stuff, but idk.  do you have any ideas?  also, maybe a paint program would be good, how would I get mouse coordinates relative to the window (will that be a command added soon?)
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 11:14:41 am
Hmm, I would go with the game actually, a browser would be way to hard to start off with (trust me I've tried x.x).
actually I do know how, just hold on a sec, I'll tell you.

EDIT: I've made an event handler that will log the mouse X and Y location for you. I'll make some more stuff later. (ie: telling you where it is relative to the current window and such)
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 12:03:36 pm
here is my app, it isn't working yet
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 07:08:05 pm
Ok, here is a new version. Changes are as follows:
Launcher icon now toggles visibility, no longer will you need to use the red button to close it. There are some small changes. You can now get the current X and Y location of the mouse by reading from MOUSE_X and MOUSE_Y.
Title: Re: jBasic OS
Post by: jnesselr on June 21, 2010, 07:10:23 pm
what about mac?
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 07:33:53 pm
I think the Linux one should work on mac, but I haven't been able to test it...my sister wont let me install ff on her mac and test it.
I am currently working on adding icon support for apps, but I haven't been able to add it yet to windows, just the launcher.

EDIT: actually new version, this one lets people toggle/hide/unhide the launcher. I also added a functon to allow someone to hide any object, same with unhiding it. randomInt(a,b) was added from the jBasic library, same with rand() which returns false or true randomly.
Icons are supported now, on both versions, if you make your own app you should make a icon.png that is square and 10x10 or bigger and place it in your apps main folder.
Title: Re: jBasic OS
Post by: Eeems on June 21, 2010, 10:38:45 pm
New version:
      new commands:
          file_mkdir()
          file_rename()
          file_copy()
          file_move()
Title: Re: jBasic OS
Post by: _player1537 on June 21, 2010, 11:02:32 pm
w00t made a program for this that lets you open/close the start menu by pressing `.  Not bad for never using java until now ;)
Code: [Select]
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);
}
}
Title: Re: jBasic OS
Post by: Eeems on June 22, 2010, 12:16:56 am
This has been integrated into the main code everybody :P
oh yeah, it's javascript not java, there is a difference :P
Title: Re: jBasic OS
Post by: _player1537 on June 22, 2010, 10:17:16 pm
I wrote a few (1 or 2) more apps for this, and made the MouseHook automaticly loaded at startup.  I also added a feature where when you hover of the clock (or the launcher icon) it opens it (for the launcher icon, it toggles the menu being open).  Check it out if you have time ;)

note: this will not probably not work just taking the apps over, I added a lot of stuff to it (added, modded, same thing ;)

Edit: this is  the linux version btw, will not work in windows
Title: Re: jBasic OS
Post by: Eeems on June 22, 2010, 11:56:19 pm
What are the apps you made?

Ok, new version that will update the core files automatically (unless you delete Updates.js) so enjoy :) I have not tested it on Windows yet, but it should work.

EDIT: oh yeah x.x
windos people you will need to run it and run the command updater_update() in the command app, Go to updates/ and rename updatesDB.xml to localDB.xml, sorry I forgot to x.x
Title: Re: jBasic OS
Post by: _player1537 on June 23, 2010, 12:13:23 am
well...I've made:
AB-press Enter and it makes over 9000 buttons...well it continues to make buttons.
KeyHook-press ` to open/close the main menu
JBasicA-a demo of how to use JBasic with jBOS
gui-an app I was working on to make a gui similar to gedit
MouseHook-an app I made to where you hover over the main menu icon, and it opens it, closes it when you rehover it.  It also used to be incharge of the clock thing (where you hover over it and it shows the system time/date) but I've fixed that now because it was messing up on larger resolutions

I've also modded the kernal app (or maybe the window.js one) to include a startup routine, and threw a few folders for testing purposes in the root/home folder.  Oh and I changed the main menu icon, as well as the alert icon :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 23, 2010, 12:30:49 am
Nice to see this progressing :)
Title: Re: jBasic OS
Post by: Eeems on June 23, 2010, 10:00:48 am
If you have left it running long enough, you will notice that it will have updated! you will have a system clock :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 23, 2010, 11:01:43 am
Tried it, nice. Only one suggestion would be to make the Start menu close when clicking a program in there, though, or make the programs appear in the middle of the screen.
Title: Re: jBasic OS
Post by: _player1537 on June 23, 2010, 11:29:43 am
I was thinking of going in and adding that.  Eeems, you want to get this one, or can I try it?
Title: Re: jBasic OS
Post by: Eeems on June 23, 2010, 12:13:26 pm
Well I've been meaning to for a while, and it shouldn't be too hard, but it would require changing the jBKernel.js file which I would then have to release a new package. I'll work on it when I finish fixing the automatic update.

EDIT: Windows test for _player.
Title: Re: jBasic OS
Post by: _player1537 on June 24, 2010, 12:54:25 pm
here are some routines, file_wline and file_rline (write/read line).  They will write/read to a specific line in jBOS of a file.  Thanks to KermM for the main code for each :)  Now its time to write some programs to add in my mods to jBOS ;)   jk.  Anyways, here ya go.
Code: [Select]
function file_rline(path,line){
    file = file_read(path);
    lines = file.replace(/(\r\n|\r|\n)/g, '\n').split('\n');
    return lines[line];
}
Code: [Select]
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);
}
(btw, I threw these in at the bottom of file.js)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 24, 2010, 01:36:32 pm
Could you explain a bit more? Is it some sort of ability to use some sort of self-modifying code in jBasic or is it to install mods?
Title: Re: jBasic OS
Post by: _player1537 on June 24, 2010, 01:42:15 pm
its mainly for programs to take input from files.  It can be used to do SMC, which I will probably end up doing, so I can keep my mods from update to update.  KermM posted a few more routines on cemetech for file manipulation.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 24, 2010, 01:50:31 pm
Aaah good :)
Title: Re: jBasic OS
Post by: Eeems on June 24, 2010, 03:07:08 pm
ok, new version, auto-updating is still broken for windows, no idea why...:/ and this one fixes the linux one.
Title: Re: jBasic OS
Post by: Eeems on June 24, 2010, 05:35:47 pm
ok, app installing on linux works! still having issues with windows though. To install an app, just type in zip_install_app_dialogue() into the command app and run it.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 24, 2010, 05:46:41 pm
Mhmm interesting. I assume the apps have to be written in jBasic and it inserts them in the code, right?
Title: Re: jBasic OS
Post by: Eeems on June 24, 2010, 05:53:13 pm
no they are written in jBOS code, but if you want jBASIC you can just have your jBASIC app in the app folder and iframe to it :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 24, 2010, 06:03:05 pm
aaaah ok I see. I thought both languages were kinda similar (in terms of coding third-party apps)
Title: Re: jBasic OS
Post by: Eeems on June 24, 2010, 06:48:11 pm
well there were some simularities, but jBOS is much different in many ways. jBOS is aimed at windows and stuff, jBasic is aimed at games. jBOS was inspired by jBasic, but it has taken a huge step away.
Title: Re: jBasic OS
Post by: DJ Omnimaga on June 24, 2010, 08:24:09 pm
Aaaah ok I see^^
Title: Re: jBasic OS
Post by: _player1537 on June 24, 2010, 08:29:13 pm
you can still use jBasic with jBOS, one of the main differences (iirc) is jBasic uses html, jBOS uses javascript only.  idk, I had to create an app.html to use jBasic
Title: Re: jBasic OS
Post by: Eeems on June 24, 2010, 08:47:11 pm
actually they both use HTML, just for developing for jBasic you have to do some HTML work, but with jBOS all of it is with javascript (although you can use HTML for in the javascrit. ie: defining the content of a window.).
Title: Re: jBasic OS
Post by: _player1537 on August 14, 2010, 09:01:27 pm
I managed to write a browser app, it allows you to enter the URL to go to, and makes the app fullscreen (Note to self: Add a full screen button to each window).  As soon as I see Eeems again to help me make the dot something file that allows auto installing of the app to jBOS, I'll upload.  (Plus a couple of changes and fixes ;))
Title: Re: jBasic OS
Post by: DJ Omnimaga on August 16, 2010, 08:31:15 pm
Cool, I'll try it when it is posted.
Title: Re: jBasic OS
Post by: _player1537 on August 16, 2010, 09:50:54 pm
Yay!  :D  I'll try to get a windows version up and running (I use linux most often for jBOS)  Expect it in... an hour at most :)

Edit: *Fanfare plays*  Tada!  I got it done :D

For the record, I pretty much just took my jBOS directory that I use in linux, cut a few parts off, and packaged it up.  In windows, I updated a bunch of stuff (I used to have 5.0 I think).  If you want/need the update stuff for either linux or windows, you will need to get it from another package, sorry.

New features:
-A maximize button!  When clicked, it will make the screen as large as it can be (you will probably want to be full screen when doing that).  To shrink it down, you should probably use the minimize button to shrink, and then unshrink with the same button.
-A web browser!  You can type in a URL, and it will make an <iframe> which you can surf the web using (which I'm posting this from).  The linux version has a slightly better version of the browser that supports (primitive) history.  Windows file management stuff is... fairly difficult imo.
-A reboot button!  In the top right corner, there is a small power button, if you click that, it will do the equivilent of refreshing the page, or rebooting :D
-A calculator!  No, not a TI-calculator, that'll come later ;)  This is just a small four function calculator that /ussually/ works.  I'll get around to fixing it one day >.>
-A kill all sequence!  Press Ctrl-Alt-` to kill every single window that is open.
-A button to open the main menu!  Press ` to open/close the main menu.


The app "APP" is something that will let you get the keycodes for whatever button you press.  The downside is that it creates more and more and more windows the longer you hold a button, so a reboot is probably best after using it.  I just realized in the windows version that the clock doesn't quite work right... So I will look at that, and try to get it fixed.  The app "Type" is something I was working on, not really anything, so don't waste too much time on it.  The app "Login" is just for looks for now, it doesn't actually log you in or anything (just loading boot.html lets you do that).   And remember, most of this is in the Alpha state, so it will probably get fixed at some point or another :)

Enjoy :D
Title: Re: jBasic OS
Post by: DJ Omnimaga on August 17, 2010, 11:16:44 am
Hmm I am a bit confused how to use this version. Could you post visual instructions????
Title: Re: jBasic OS
Post by: _player1537 on August 17, 2010, 05:38:04 pm
Sure :D

Ok, first you download and extract the file (I assume you are using windows, so you download the windows version)

Then you open the directory (folder) you extracted the folder to.  Find the file "boot.html" and right-click it and say "Open with > Firefox".
(http://img.removedfromgame.com/imgs/1282081901-jBOS1.png)

Then you have to check "Remember my decision" and click "Allow"
(http://img.removedfromgame.com/imgs/1282082227-jBOS2.png)

Once it is open, you can open the main menu (where the apps are kept as of now) with one of two ways: Click the button in the top left to toggle the main menu open or close, or you can press the ` key (also has ~ on it) to toggle it open or closed.
(http://img.removedfromgame.com/imgs/1282082260-jBOS4.png)

To use various apps (note: will enforce that every app has a help file at some point) click on the icon in the main menu.  (I prefer to have firefox in fullscreen mode, f11 on my computer).
(http://img.removedfromgame.com/imgs/1282082290-jBOS5.png)
(http://img.removedfromgame.com/imgs/1282082315-jBOS6.png)


(Note: I'll go through and add some pictures for reference in a moment.)
Title: Re: jBasic OS
Post by: {AP} on August 17, 2010, 07:33:56 pm
Why do you need a browser in a browser? xD

I mean, it's cool that it works, but... why?
Title: Re: jBasic OS
Post by: _player1537 on August 17, 2010, 09:15:05 pm
idk... just for nostalgic purposes (I think that's the right use of the word x.x)

I think it'd be cool to have it so anything you need to do, could be found in jBOS.  There are valid reasons why most of the stuff shouldn't even be attempted in jBOS, like a web browser, or a text editor.  But the web browser is teaching me about iframes, the text editor will teach me how to do filesystem stuff in windows (I can do it in linux, just not windows).  Mostly its a learning experience, and it gives me /something/ to do.  I find some trouble thinking of stuff to do on a calculator, but if I'm trying to make a full fledged OS, there are plenty of things to do and learn.  I think that is the main reason.
Title: Re: jBasic OS
Post by: DJ Omnimaga on August 18, 2010, 12:26:34 pm
Thanks for the info above, I get it now ^^

Title: Re: jBasic OS
Post by: _player1537 on August 20, 2010, 07:16:20 pm
Great to hear!  How are you liking it so far?  As soon as I figure out how to do some CSS, I'll be able to have a desktop background :)
Title: Re: jBasic OS
Post by: willrandship on August 20, 2010, 08:38:27 pm
Hmm...I wonder what would happen if I opened this with a text-based Linux CLI browser? :P
Title: Re: jBasic OS
Post by: _player1537 on August 22, 2010, 09:37:25 pm
Unless that text based CLI browser was based on Firefox, nothing.  If it was... idk I bet it wouldn't display it correctly, except for the text, as I think they do not use CSS for those types of browsers.  Plus, iirc they do not allow you to use a mouse, so parts of the system would be hindered I would bet. 

But still, go ahead and try it, I'd like to see what it does :)
Title: Re: jBasic OS
Post by: _player1537 on September 06, 2010, 02:34:30 pm
*bump*
Wrote a small jBOS application that helps with creating matrix(es?).  Just click the application in the main menu, enter height, then width.  Its a little backwards, and sometimes messes me up.  You then get a new window that you type in each elements data.  Pressing tab will bring you to the next one (that way its a little easier to edit).  You then press the "Create Matrix" Button to make it.  The code that results should work in SC.

To remove the application from the .jba file, there are two ways:
1) Open up the command application, and type in "zip_install_app_dialogue()" and press enter (or click the go button).  It should bring up a new window asking you to find the .jba file you want to install, click on that, and then "restart" (F5 or press the power button I added recently) to be able to use the app.
2) Open up the .jba file like it was a .zip (you may have to rename) and create a new folder in the apps directory named "MatrixGen" and export the data from the .jba into that folder.

Enjoy :D
Title: Re: jBasic OS
Post by: Eeems on September 06, 2010, 04:02:24 pm
shouldn't it have my installer app? Or did you not include it?
Also, adding backgrounds should be easy, in the boot portion somewhere add
Code: [Select]
document.body.background = "relative path"; the path could be a variable set in the globals.js
Title: Re: jBasic OS
Post by: DJ Omnimaga on September 06, 2010, 04:07:08 pm
Mhmm do you mean matrices for use in tilemaps? Can it do multiple sizes? One thing I disliked in BASIC tilemapping was editing matrices and strings. Even with a map maker, editing massive maps is a major hassle, because I only see 12x8 on the screen at once and in the calc matrix editor, 3x5 or something
Title: Re: jBasic OS
Post by: _player1537 on September 06, 2010, 04:18:53 pm
Yep, the max size is probably around 30x20, but that's just a guess.  I just mean matrices in general, for whatever you may need a matrix for. 
Title: Re: jBasic OS
Post by: DJ Omnimaga on September 06, 2010, 04:22:49 pm
ah ok. Now if only it was easy to implement the ability to assign small images of the sprites you need to specific numbers to help in tilemap making. Still, nice idea. Hopefully some Firefox users may find it useful.
Title: Re: jBasic OS
Post by: Eeems on October 04, 2010, 07:55:01 pm
Not for mac's (http://www.omnimaga.org/index.php?action=dlattach;topic=4706.0;attach=3638)
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 04, 2010, 08:04:27 pm
Mhmm in Firefox 3.6.8 I only see "loading" on black bg and nothing happens.
Title: Re: jBasic OS
Post by: Eeems on October 04, 2010, 08:07:12 pm
Hmm, did you get a looking like this?
(http://puu.sh/e26)
If so make sure to allow it
Title: Re: jBasic OS
Post by: _player1537 on October 04, 2010, 08:11:12 pm
Don't forget, you also need an extension, I'll edit in a link to it :)
https://addons.mozilla.org/en-US/firefox/browse/type:7

Choose either quicktime or windows media player (on that list)
Title: Re: jBasic OS
Post by: Eeems on October 04, 2010, 08:14:49 pm
Don't forget, you also need an extension, I'll edit in a link to it :)
pardon? Also there is a small problem with the sound driver that I can't remember if I fixed that broke launching, here is a release that fixes it:
Title: Re: jBasic OS
Post by: _player1537 on October 04, 2010, 08:15:50 pm
I thought I had to install a special plugin to run jBOS2 due to the sound driver?  Meh, guess its fixed :P
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 04, 2010, 09:24:11 pm
Hmm, did you get a looking like this?
(http://puu.sh/e26)
If so make sure to allow it
Not at all, it just sat at Loading.
Title: Re: jBasic OS
Post by: Eeems on October 05, 2010, 12:41:08 am
I thought I had to install a special plugin to run jBOS2 due to the sound driver?  Meh, guess its fixed :P
you shouldn't have too it usually is already installed. Fixed it though for when it's not installed it won't error.

DJ: strange, that should pop up. Since it doesn't nothing will run because it doesn't have permission to run. Don't know why your copy isn't givin that.
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 05, 2010, 12:47:26 am
I guess I'Ll probably have to forget about jBOS :/
Title: Re: jBasic OS
Post by: Eeems on October 05, 2010, 09:07:30 am
It's very strange. Do you have firebug installed? If you do you can try checking if there are errors thrown on loading the page.
Title: Re: jBasic OS
Post by: shmibs on October 05, 2010, 09:33:12 am
Hmm, did you get a looking like this?
(http://puu.sh/e26)
If so make sure to allow it
Not at all, it just sat at Loading.
same for me. i have yet to get any version of jbos to run
Title: Re: jBasic OS
Post by: Eeems on October 05, 2010, 10:48:48 am
Maybe there was another step that I forgot to add that has to do with changing preferences or something, any of this ringing a bell _player?
Title: Re: jBasic OS
Post by: LordConiupiter on October 05, 2010, 11:26:57 am
it's not working or me! I'm using Google Chrome 6.0.4xx.xx on Windows 6 SP2, and the only thing I see in Chrome, Safari and IE is a black screen!
Title: Re: jBasic OS
Post by: Eeems on October 05, 2010, 11:30:21 am
That's because it doesn't work on anything but Firefox as I have said before.
also, windows 6?
Title: Re: jBasic OS
Post by: LordConiupiter on October 05, 2010, 11:50:02 am
oke, im sorry for not reading everything completely, but I'll check it out in FireFox.
and yes, it's really 6 (http://en.wikipedia.org/wiki/Windows_Vista)
Title: Re: jBasic OS
Post by: Eeems on October 05, 2010, 11:50:43 am
Ah ok, np
oh lol, well most people just call it vista so I was confused if you meant to say 7 or not

EDIT:
if you aren't getting that go to about:config and make sure that this setting looks like this
http://puu.sh/gg7
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 05, 2010, 02:19:32 pm
Ok I just tried again and weirdly enough, now it works. It seems the script execution warning pop up only shows up when Firebug is opened, for me. X.x

Do you think in the future it will be possible to not have that script warning show up like over 9000 times when loading? Some people may not want to click "Remember this action" since other sites may pose a threat. Anyway, now it looks really nice. Suggestion, allow the user to turn off animations/effects if they got older computers and have options to make the notices at the bottom-right of the screen show up for longer so we get time to see them.
Title: Re: jBasic OS
Post by: LordConiupiter on October 05, 2010, 03:01:19 pm
it's still not working for me! I have FF 3.6 and Windows MediaPlayer 11 plugin installed, but I see nothing but "Loading..." in the upper left corner of the black page.
Title: Re: jBasic OS
Post by: FinaleTI on October 05, 2010, 03:04:33 pm
I had the same problem as DJ and LordConiupiter, but I installed Firebug, then enabled it for the tab I had jBOS in, refreshed and it worked.
Title: Re: jBasic OS
Post by: Eeems on October 05, 2010, 06:24:41 pm
Ok I just tried again and weirdly enough, now it works. It seems the script execution warning pop up only shows up when Firebug is opened, for me. X.x

Do you think in the future it will be possible to not have that script warning show up like over 9000 times when loading? Some people may not want to click "Remember this action" since other sites may pose a threat. Anyway, now it looks really nice. Suggestion, allow the user to turn off animations/effects if they got older computers and have options to make the notices at the bottom-right of the screen show up for longer so we get time to see them.
Strange
Um, well no I can't do that because that is how often it calls upon those permissions, and the remember this action is only for that one page and it doesn't effect others so you should be fine.
It would take a lot to turn off animations due to the fact that I'm using someone else's library to do it, so that probably wont be an option, sorry. Notices at the bottom could be done with a little tweaking to some stuff, I'll look into it :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 06, 2010, 12:04:41 am
Ah ok. My concern was if it ran extremly slow on anything older than a quad-core or something. Also Had this been cross-browser compatible I would most likely have created a sub-forum for it under projects, since it would have a larger audience.
Title: Re: jBasic OS
Post by: _player1537 on October 06, 2010, 12:14:23 am
OHHHHHHHHHHH

That's the problem!  I totally forgot to say that in order to get it to even boot  I had to have firebug open.  My guess: It relies to heavily on console output.  Fix: Download and run firebug when running jBOS.  No idea how Eeems will fix it though >.>
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 06, 2010, 12:20:15 am
Oh I see. X.x

I guess it is dependent on Firebug, then? D:
Title: Re: jBasic OS
Post by: Eeems on October 06, 2010, 12:36:04 am
First off making it cross browser is impossible due to the fact that firefox is the only one that has the file commands I need. It shouldn't rely on firebug die to the fact that firefox can handle console logging without firebug, firebug just puts everything together into a mice interface. I need to put more work into this I guess though and figure out of there is a way around it.
Also I developed this on a singlecore with 2GB pelt ram, so anything more then my single Turion should be fine of course it may be a little slow at loading if you load it just as firefox starts as I've found out :p but other then that it's good :) it runs nice and snappy with little slowdown unless you have CPU hogs running, I usually have firefox with ~3 tabs open, thunderbird, notepad++, push, avast and the post notifier running while I run jBOS.
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 06, 2010, 12:44:40 am
Ah ok I see. I wish all other browsers supported all commands x.x. They make things harder for web devs...
Title: Re: jBasic OS
Post by: Eeems on October 06, 2010, 01:16:19 am
Yeah well I'm using commands that web developers wouldn't because it's all client side stuff, and it's a security risk if everybody could use it. It's usually reserved for addons to firefox :p
It would be nice if they all had the same client side stuff though. Making addons for more browsers would be easier.
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 06, 2010, 01:23:44 am
Yeah. Although personally things would be much better if there was only one single browser and it was good. But again, if a browser had a monopoly the company might not care about making it good x.x
Title: Re: jBasic OS
Post by: Eeems on October 06, 2010, 01:28:35 am
It would be better if they all followed the rules to the T on how things are suppose to be rendered. But everything has to have it's own tiny little changes...:(
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 06, 2010, 01:40:57 am
Right, yeah that could work too. Currently, no site, even ones that follows standards, will show fine in all 3 most web-compliant browsers. Even Firefox fails to render some sites sometimes.
Title: Re: jBasic OS
Post by: Netham45 on October 06, 2010, 02:47:09 am
Couldn't get it to even boot without firebug's console output running.
Title: Re: jBasic OS
Post by: Eeems on October 06, 2010, 10:57:46 am
Right, yeah that could work too. Currently, no site, even ones that follows standards, will show fine in all 3 most web-compliant browsers. Even Firefox fails to render some sites sometimes.
Yeah that's because the coder is trying to make it work for all the browsers but didn't quite get it right
Couldn't get it to even boot without firebug's console output running.
Strange, did you get any errors in the error console?
Title: Re: jBasic OS
Post by: Eeems on October 07, 2010, 07:50:43 pm
Ok, new version :D this one has a keyboard driver :D so apps can call $.keyboard.getKey(keycode) which will return true if it is currently down false if it isn't.The keyboard driver can also create keyhooks, so when a certain key is pressed a function is executed, currently there is a test hook in place which will log "space is pressed" if you press the space key. The keyhook task runs every second, but I might switch it up to run only on a keypress instead of a task.
How to create a keyhook:
Code: [Select]
var key = new Keyhook(keycode,function(){
   //function content goes here
});
key.init();  //adds the keyhook
key.remove();  //removes the keyhook so it wont run
I might as well talk about tasks too:
Code: [Select]
var task = new Task(app id,task name,task id,interrupt,function(){
   //onstart function
},function(){
  //onexec funtion
},function(){
  //onstop function
},function(){
  //onend function
});
task.init(); //adds the task to the task list, disabled
task.start();  //initializes the task, running onstart and then runs onexec every interrupt
task.stop();  //stops the task, keeping it in the list, runs onstop
task.end();  //removes the task from the tasklist and runs onend
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 07, 2010, 08:18:51 pm
Nice, by keyhook can it hijack my computer keyboard or something, though? X.x
Title: Re: jBasic OS
Post by: Eeems on October 07, 2010, 08:19:50 pm
no, it will only effect what happens in jBOS, so it will run code if you press the specified key
Title: Re: jBasic OS
Post by: DJ Omnimaga on October 07, 2010, 08:29:22 pm
Ah ok good to hear :)
Title: Re: jBasic OS
Post by: Eeems on October 07, 2010, 09:35:05 pm
Don't worry javascript can't do anything like that :P
Title: Re: jBasic OS
Post by: Eeems on February 14, 2011, 01:07:07 am
Well I got to working on a ground up remake of jBOS2, titles Teal, and here it is :)
Early alpha, just for those who want to play around with it and want to try to develop some apps for it. I'm not done the api yet though.
Check doc/ for a document on how to get started on coding apps, look on jQuery's api documentation for how to use that, and apps/ includes two example apps :)

Firefox only as always.

EDIT: remember to have http://puu.sh/gg7 set as such to make sure it can work.
Title: Re: jBasic OS
Post by: shmibs on February 14, 2011, 01:31:50 am
looking spiffy!
things i noticed:
when more than one of the "test app" was opened at once they refused to close. i have replicated this, but it doesn't seem to be consistent.
opening more apps than can fit on the top status bar at once starts adding them below the bar(where the x button doesn't work). this seems more like an "i haven't written the code for that yet" than a bug, though :P
here's a screenie of eeem's pretty transparencies for you non-firefox people.
Title: Re: jBasic OS
Post by: DJ Omnimaga on February 14, 2011, 01:32:47 am
Holy necropost! Looks nice. I wonder if it's fast on older machines? (By fast, I mean faster than MySpace's 1 FPS scrolling)
Title: Re: jBasic OS
Post by: Eeems on February 14, 2011, 02:27:19 am
I should disable the ability for multiple of the same window to be open. And yes I haven't addressed the taskbar filling up yet, although it is on my mind.
DJ: I mainly develop on a single core, so this should work good on older machines :)

Anybody thinking about maybe writing some apps for this? :D
Title: Re: jBasic OS
Post by: DJ Omnimaga on February 14, 2011, 02:59:41 am
Good to hear. I doubt I'll develop for it, though, since I don't code much for computer. :(

Title: Re: jBasic OS
Post by: Munchor on February 14, 2011, 07:48:41 am
(http://www.omnimaga.org/index.php?action=dlattach;topic=3475.0;attach=6124;image)

This looks AWESOME!
Title: Re: jBasic OS
Post by: Eeems on February 14, 2011, 02:55:02 pm
Ah ok DJ
Scout: thanks :D
Title: Re: jBasic OS
Post by: Munchor on February 14, 2011, 04:26:34 pm
Do you have a video or is that at some website? I'd love to try it (even despite it is in a stage below Alpha, it seems) ;D
Title: Re: jBasic OS
Post by: Eeems on February 14, 2011, 06:14:22 pm
http://ourl.ca/6072/173890 <- this post contains a demo

EDIT: New update :) launching apps is nicer :)
Title: Re: jBasic OS
Post by: Eeems on February 15, 2011, 12:02:32 am
http://puu.sh/Xzs
http://puu.sh/Xzu
More goodness :)

EDIT: http://img.removedfromgame.com/imgs/screen.png
Title: Re: jBasic OS
Post by: Munchor on February 15, 2011, 07:31:44 am
Looks perfect Eeems! Can't wait for an online version of it for experimenting as I've tried it offline :)
Title: Re: jBasic OS
Post by: Eeems on February 15, 2011, 09:30:30 am
This will only be offline due to limitations firefox puts in place on certain XPCom functions I use.
Title: Re: jBasic OS
Post by: Eeems on February 15, 2011, 03:54:09 pm
Ok new version :) with all the nice graphics shown in the last screenshot :D
Title: Re: jBasic OS
Post by: Eeems on February 17, 2011, 12:23:20 am
Head over to http://eeezor.ec3club.tk/#Files to get the most recent version if you want it :)
You also might be able to catch a few development apps I'm working on :)
Title: Re: jBasic OS
Post by: DJ Omnimaga on February 17, 2011, 04:48:03 am
I should probably try this again eventually :P

Btw I can't open the file on your site: I get an error when downloading. You should probably put instructions in the file browser. :/
Title: Re: jBasic OS
Post by: Eeems on February 17, 2011, 09:55:46 am
Strange, what's the error? I can open it fine, even on my iPod. When you click on the file and the modal window opens up, did you click open as, and then raw file?
Title: Re: jBasic OS
Post by: Munchor on February 17, 2011, 11:35:40 am
Eeems, instead of making us download the .zip couldn't you host at your website, so we could try it online, in browser?
Title: Re: jBasic OS
Post by: Eeems on February 17, 2011, 01:31:39 pm
I've had to answer this a few times before, but I guess you didn't read back to it.
It won't run off of a server, the commands it uses will only work on local file.
I will be implementing downloading updates directly into it later, but I havent gotten to coding that yet.
Title: Re: jBasic OS
Post by: Munchor on February 17, 2011, 01:40:31 pm
I've had to answer this a few times before, but I guess you didn't read back to it.
It won't run off of a server, the commands it uses will only work on local file.
I will be implementing downloading updates directly into it later, but I havent gotten to coding that yet.

Oh I see then. Sorry for asking you ONCE again.
Title: Re: jBasic OS
Post by: Eeems on February 17, 2011, 04:14:26 pm
Np, just gets a little annoying being asked multiple times :P
Title: Re: jBasic OS
Post by: willrandship on February 17, 2011, 05:43:12 pm
Maybe like Minecraft does it, open in browser and it downloads to your PC and runs.

Just a thought.
Title: Re: jBasic OS
Post by: Eeems on February 17, 2011, 07:15:23 pm
That's exactly what I was thinking :P
Title: Re: jBasic OS
Post by: DJ Omnimaga on February 18, 2011, 04:26:06 am
Strange, what's the error? I can open it fine, even on my iPod. When you click on the file and the modal window opens up, did you click open as, and then raw file?
The file browser can't handle this file. Then I decided to open as zip file, and when I tried opening it on my computer it said Cannot open the file.
Title: Re: jBasic OS
Post by: Eeems on February 18, 2011, 12:14:42 pm
Yeah, my thing can't handle zip files, so open as raw file.
Don't know what happened with the open as zip though.
Title: Re: jBasic OS
Post by: Eeems on February 18, 2011, 06:20:32 pm
http://code.google.com/p/jbos3-teal/
SVN of the project, will be kept up to date, so if you want the most recent copy, just checkout the svn.
If anybody wants to help with the project, just let me know Smile
Title: Re: jBasic OS
Post by: Eeems on February 19, 2011, 01:22:17 pm
Applications can now save their own settings, All the settings are saved under var/ with the extension set. Settings are saved under <variable name>.defaults in any manner the app coder wishes.
Title: Re: jBasic OS
Post by: DJ Omnimaga on February 22, 2011, 04:03:13 pm
Nice to see new progress. I'll also have to try raw files too, to see if they work.
Title: Re: jBasic OS
Post by: Eeems on February 27, 2011, 06:19:42 pm
Ok, a few thins.
Settings are now stored under etc/<file name>.set
Auto updating now works, and updates (currently, but can be expanded to include apps when I code it into the apps to register on run) work for bin/*.td3 and boot/Kernel.js
So now, except for app updates, and extensions to jQuery and other libraries, you can just run it and it will update the files at boot up, or whenever it next checks and there are updates. If you have bin/Growl.alerts.td3 (which is optional) it will alert you when updates have been applied so you can restart if you wish. Also, when I get around to making a terminal viewer app you can see the logs as they happen of updates.
Title: Re: jBasic OS
Post by: DJ Omnimaga on February 28, 2011, 02:50:39 am
Cool to hear. By the way will you post a new video of it soon? (For those who don't want to switch to Firefox to try it)
Title: Re: jBasic OS
Post by: Eeems on February 28, 2011, 10:02:22 am
Yeah I should, just haven't had the time yet, or thought of it. Thanks for reminding me :)
Title: Re: jBasic OS
Post by: ParkerR on March 09, 2011, 04:48:15 pm
Eeems, nice job on jBOS. The second is very nice. Can't wait to see what comes next. :)
Title: Re: jBasic OS
Post by: Eeems on March 09, 2011, 05:07:55 pm
What about jbos3-teal?
Title: Re: jBasic OS
Post by: ParkerR on March 09, 2011, 05:42:12 pm
I forgot that was out XD Will check out now
Title: Re: jBasic OS
Post by: Eeems on March 09, 2011, 06:06:51 pm
Lol, no problem :)
Title: Re: jBasic OS
Post by: willrandship on March 09, 2011, 06:29:09 pm
err....I get this in teal :P
Loading....
  System OS: "Linux"
  System Slash: "/"
  System Directory: "/home/william/CalcStuff/jBasicOS/jbos3-teal-read-only/"
Loading bin/
  100%
  zip.manager.td3
Task Manager loaded
System Console Manager loaded
Moving to new console.
I was getting a different error before,
Loading....
  System OS: "Linux"
  System Slash: "/"
  System Directory: "home\william\CalcStuff\jBasicOS\"
Loading bin/
  0%
  Listing Directory
but then I got the svn one, and I get the first one. :(
Title: Re: jBasic OS
Post by: Eeems on March 09, 2011, 06:30:51 pm
err....I get this in teal :P
Loading....
  System OS: "Linux"
  System Slash: "/"
  System Directory: "/home/william/CalcStuff/jBasicOS/jbos3-teal-read-only/"
Loading bin/
  100%
  zip.manager.td3
Task Manager loaded
System Console Manager loaded
Moving to new console.
I was getting a different error before,
Loading....
  System OS: "Linux"
  System Slash: "/"
  System Directory: "home\william\CalcStuff\jBasicOS\"
Loading bin/
  0%
  Listing Directory
but then I got the svn one, and I get the first one. :(
Erm, a little confused.
Title: Re: jBasic OS
Post by: willrandship on March 09, 2011, 06:44:26 pm
Here's a little clearer:
I dled the latest version from your site, and it gave me this when I ran it, stopped there.

Loading....
  System OS: "Linux"
  System Slash: "/"
  System Directory: "home\william\CalcStuff\jBasicOS\"
Loading bin/
  0%
  Listing Directory

Then, I decided to try the svn one, and it gave me this.

Loading....
  System OS: "Linux"
  System Slash: "/"
  System Directory: "/home/william/CalcStuff/jBasicOS/jbos3-teal-read-only/"
Loading bin/
  100%
  zip.manager.td3
Task Manager loaded
System Console Manager loaded
Moving to new console.

I did give it permissions, btw
Title: Re: jBasic OS
Post by: Eeems on March 09, 2011, 07:25:08 pm
Ah ok, well the svn should work better, it is newer code.
I've just tested it though and it seems to be failing at starting something, thanks for reporting it I'll try to get it working.

EDIT: error should be fixed now, update the svn copy and then try running it again.
Title: Re: jBasic OS
Post by: willrandship on March 09, 2011, 07:34:58 pm
OK, I will :)

Edit: and, it works! much fancier than v2, but no apps.....are v2's apps compatible?
Title: Re: jBasic OS
Post by: Eeems on March 09, 2011, 08:17:16 pm
OK, I will :)

Edit: and, it works! much fancier than v2, but no apps.....are v2's apps compatible?
There are a few system apps, but no other ones. No v2's apps are not compatible, but I could work on porting a few. Let me know which ones you want ported and I'll work on them.
I also have the source for an app server if anyone wants to create their own apps. I don't have the GUI options to change servers as of yet, but I will add them later.
Title: Re: jBasic OS
Post by: willrandship on March 09, 2011, 08:18:17 pm
The browser is what I missed the most :P and the physics engine
Title: Re: jBasic OS
Post by: Eeems on March 09, 2011, 08:19:52 pm
The browser is what I missed the most :P and the physics engine
Hmm, I could totally make a new physics engine, and a new browser :)
I will get right on converting them, thanks for letting me know :)
Title: Re: jBasic OS
Post by: willrandship on March 09, 2011, 08:53:50 pm
Yay! now with the web browser I can pretend it has a few games :P
Title: Re: jBasic OS
Post by: Eeems on March 09, 2011, 11:19:47 pm
Haha :P
Well they wont be completed for a little while because I'm focused on a secret project atm
Title: Re: jBasic OS
Post by: DJ Omnimaga on March 10, 2011, 03:47:06 am
/me is curious what is the secret projects. :P