webOS Nation Forums >  webOS apps and software >  webOS development > Making fake programs is fun :)
Making fake programs is fun :)

  Reply
 
LinkBack Thread Tools Display Modes
Old 06/29/2009, 06:10 PM   #1 (permalink)
Member
 
Join Date: Jan 2009
Posts: 123
Likes Received: 0
Thanks: 9
Thanked 14 Times in 6 Posts
Default Making fake programs is fun :)

I'm having fun with the SDK...I just wish we could get access to the API's so we could interact with the built in stuff!

__________________
Jordan Mack
webOS Chat
jmack549 is offline   Reply With Quote
Old 06/29/2009, 06:11 PM   #2 (permalink)
Member
 
Blubble's Avatar
 
Join Date: Jun 2009
Location: Silicon Valley, California
Posts: 1,025
Likes Received: 0
Thanks: 37
Thanked 444 Times in 161 Posts
Default

There are a few sample apps that give you some insight into the available APIs.
Blubble is offline   Reply With Quote
Old 06/29/2009, 06:15 PM   #3 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

I don't know why... but playing around with the SDK is so incredibly difficult for me!

I'm trying to modify the Hello World sample app given by something as simple as... adding a slider... and I'm failing miserably! I included a link to the slider-assistant.js in the sources.json file, and a div line in the first-scene...

what else is needed?
SirataXero is offline   Reply With Quote
Old 06/29/2009, 06:41 PM   #4 (permalink)
Member
 
edgarwong's Avatar
 
Join Date: Apr 2009
Posts: 168
Likes Received: 0
Thanks: 8
Thanked 15 Times in 15 Posts
Default

i started by coyping the widgetsui app stripping away the stuff i dint want i had the same kind of problems as you, but with the audio app
edgarwong is offline   Reply With Quote
Old 06/29/2009, 06:55 PM   #5 (permalink)
Member
 
Join Date: Jan 2009
Posts: 123
Likes Received: 0
Thanks: 9
Thanked 14 Times in 6 Posts
Default

Yeah, I have no idea how to input a slider/selector/etc either. Seems pretty confusing.
__________________
Jordan Mack
webOS Chat
jmack549 is offline   Reply With Quote
Old 06/29/2009, 06:58 PM   #6 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

I'm working on stripping the Widgets app. It's really hard because they decided on throwing everything in that list... which is REALLY confusing for a n00b such as myself.

I managed to create a button though! hahaha

which is HUGE progress for me...

obviously as of right now, it doesn't do anything... but I plan on making it decrement count...

Lets see if I can pull this off... >.<

*crosses fingers*
SirataXero is offline   Reply With Quote
Old 06/29/2009, 07:01 PM   #7 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

SUCCESS!!!

hahahahaha

I'm so incredibly happy I have an app that has two buttons, one adds 1 to "total" while the other one subtracts 1 from the total. haha. This is incredibly exciting. This success has motivated me to figure out the slider...

When I do... I'll post back here to let you all know... in noob terms... >.<

sometimes us noobs get NO love.
SirataXero is offline   Reply With Quote
Old 06/29/2009, 07:02 PM   #8 (permalink)
Member
 
Join Date: Jan 2009
Posts: 123
Likes Received: 0
Thanks: 9
Thanked 14 Times in 6 Posts
Default

I can make stuff increment very easily in Java, but I don't know how to display this in an HTML file. I guess I could have it display the output of the Java file underneath, and when they click it run the Java file?
__________________
Jordan Mack
webOS Chat
jmack549 is offline   Reply With Quote
Old 06/29/2009, 07:06 PM   #9 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

MEGA SCORE!

I got the slider displayed on the main screen!

Let me work a little bit more and I'll put up a real simple way to pull out that code...

tbh, I don't know if Palm will get mad if I paste one line of code here? Not sure... but I'll explain it in good detail so its easy to know just basically how to show things (like sliders and numbers)

one sec...



*edit: screenshot of my butchered version of the Hello World app!*

Last edited by SirataXero; 06/29/2009 at 07:16 PM. Reason: including screenshot
SirataXero is offline   Reply With Quote
Thanked By: jmack549
Old 06/29/2009, 07:21 PM   #10 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

Quote:
Originally Posted by jmack549 View Post
I can make stuff increment very easily in Java, but I don't know how to display this in an HTML file. I guess I could have it display the output of the Java file underneath, and when they click it run the Java file?
Well, the Hello World app does it a smart way, it just outputs the initialized variable (total) in this case and then creates a button. The button's press event calls the handleButtonPress function which then increments total and updates it. So my button basically does the same thing except I put
Code:
this.total = this.total - 1;
and then update total again, so it just decrements and refreshes the already shown variable.

All of this is done within the first-assistant.js btw.

To display slider: its quite similar to the button function:
Code:
this.controller.setupwidget()
Use that function, all you have to do is figure out what the inputs to that function are. I can get more specific if you guys really need it, but most of these widgets just need the basic stuff like attributes, and model details.

That's how I got mine working! I'm going to try and see what makes the slider default in that location (shown on the screen shot above) and if I can take that slider and correspond it with the total shown above somehow...



this IS fun!
SirataXero is offline   Reply With Quote
Thanked By: jmack549
Old 06/29/2009, 07:29 PM   #11 (permalink)
Member
 
Join Date: Jan 2009
Posts: 123
Likes Received: 0
Thanks: 9
Thanked 14 Times in 6 Posts
Default

Wow, you're making great progress! I won't be able to look at it until later tonight, but the counter stuff definitely helped. I don't understand the slider still, but hopefully I'll get it when I can look at it more...
__________________
Jordan Mack
webOS Chat
jmack549 is offline   Reply With Quote
Old 06/29/2009, 07:31 PM   #12 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

Quote:
Originally Posted by jmack549 View Post
Wow, you're making great progress! I won't be able to look at it until later tonight, but the counter stuff definitely helped. I don't understand the slider still, but hopefully I'll get it when I can look at it more...
Thanks! I feel like i'm making great progress too! haha.

I guess whenever you're ready you can ask me specific questions and I can try to help you with as much as I know (which is obviously not a lot) tbh, but we can try!
SirataXero is offline   Reply With Quote
Old 06/29/2009, 07:36 PM   #13 (permalink)
Member
 
Blubble's Avatar
 
Join Date: Jun 2009
Location: Silicon Valley, California
Posts: 1,025
Likes Received: 0
Thanks: 37
Thanked 444 Times in 161 Posts
Default

It will help a lot for you to learn about CSS.
Blubble is offline   Reply With Quote
Old 06/29/2009, 07:41 PM   #14 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

Quote:
Originally Posted by Blubble View Post
It will help a lot for you to learn about CSS.
Yeah?

I figured as much... : /

I'm too impatient to just learn... I want to jump in and started hacking away. I guess i'm glad I just have the SDK and not a real phone.

I'm just messing around right now with no distinct goal... Just trying to see what I can do.

To be honest, it seems relatively easy, just a bit of a learning curve...
SirataXero is offline   Reply With Quote
Old 06/29/2009, 07:59 PM   #15 (permalink)
Homebrew Developer
 
Join Date: Jul 2011
Posts: 126
Likes Received: 68
Thanks: 43
Thanked 3,129 Times in 2,010 Posts
Default

I can't wait until my laptop comes in tomorrow! I want to download the SDK and have some fun with it. I have quite a bit of experience with HTML, and some experience in alot of other languages, so I should be fine. I just wanna play with it and make some apps!
Garrett92C is offline   Reply With Quote
Old 06/29/2009, 08:23 PM   #16 (permalink)
Member
 
Join Date: Jun 2009
Posts: 73
Likes Received: 0
Thanks: 5
Thanked 7 Times in 6 Posts
Question

Took me almost all day today and yesterday but here what i got

Zelo.png

text box does not work
murdermajig is offline   Reply With Quote
Old 06/29/2009, 08:42 PM   #17 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

Quote:
Originally Posted by murdermajig View Post
Took me almost all day today and yesterday but here what i got

Attachment 20713

text box does not work
That is awesome!

I love the faded yellow background!

I myself am trying to make a more "legit" looking app with the built in WebOS theme. I don't want to deviate much from that, but to be honest, that's a REALLY nice looking app though!

I've moved the objects in mine around a little bit so they look semi-decent now.

SirataXero is offline   Reply With Quote
Old 06/29/2009, 08:51 PM   #18 (permalink)
Member
 
Join Date: Jun 2009
Posts: 14
Likes Received: 0
Thanks: 1
Thanked 2 Times in 2 Posts
Default

Quote:
Originally Posted by SirataXero View Post
That is awesome!

I love the faded yellow background!

I myself am trying to make a more "legit" looking app with the built in WebOS theme. I don't want to deviate much from that, but to be honest, that's a REALLY nice looking app though!

I've moved the objects in mine around a little bit so they look semi-decent now.

How do you do any of that? i am dying trying to figure out how to make the slider work without calling the entire API application.
mentallydetached is offline   Reply With Quote
Old 06/29/2009, 09:04 PM   #19 (permalink)
Member
 
SirataXero's Avatar
 
Join Date: Nov 2007
Location: Rhode Island, USA
Posts: 1,739
Likes Received: 15
Thanks: 381
Thanked 398 Times in 217 Posts
Default

Quote:
Originally Posted by mentallydetached View Post
How do you do any of that? i am dying trying to figure out how to make the slider work without calling the entire API application.
Well, you HAVE to start with the Hello World app. The "samples" are all very confusing.

Go into
Code:
C:\Palm\SDK\share\tutorial
and you'll see the Hello World folder.

In that folder, go into apps/views/first.

The file you're looking for is (if you installed into the C directory directly:
Code:
C:\Palm\SDK\share\tutorial\HelloWorld\app\views\first
If you look in there, you'll see a list of div objects. This is basically how your "homepage" of your app will look. Play around with those, go into samples and extract some of those for things like sliders and text boxes and such. If you want more specific instructions let me know...

*edit: Sorry I just realized I didn't say anything about the slider. Go into
Code:
C:\Palm\SDK\share\samples\UIWidgets\app\assistants\selectors
Here you'll see slider-assistant.js. Open it up (in notepad) and look around... there's some basic instructions on how to call the slider and what to with it.

I got around to putting a slider on my app but as of right now, it doesn't really do anything... I'm trying to figure out how to link it to everything...

Again, if you need more specific instructions, message me or something... i'm too worried about posting actual Palm code directly on the forum... : /

Sorry!*
SirataXero is offline   Reply With Quote
Thanked By: prochobo
Old 06/29/2009, 09:12 PM   #20 (permalink)
Member
 
Join Date: Jun 2009
Posts: 73
Likes Received: 0
Thanks: 5
Thanked 7 Times in 6 Posts
Default

Quote:
Originally Posted by SirataXero View Post
That is awesome!

I love the faded yellow background!

I myself am trying to make a more "legit" looking app with the built in WebOS theme. I don't want to deviate much from that, but to be honest, that's a REALLY nice looking app though!

I've moved the objects in mine around a little bit so they look semi-decent now.

Well I'm experimenting with the background, gold fades to yellow for background

I cant get the textbox nor can i even make it find my name
once i get the textbox working
i will need help pulling names from the zelo.com website to the Unofficial zelo app
murdermajig is offline   Reply With Quote
Reply

 

Thread Tools
Display Modes



 


Content Relevant URLs by vBSEO 3.6.0