Page 5 of 7 FirstFirst 1234567 LastLast
Results 81 to 100 of 127
  1. #81  
    For some reason I can't create a new thread, so I'm gonna ask for a bit of help in here.

    I have some data that I'm wanting to manipulate. Now, I'm going on a limb guessing this based on what I've read and seen in other source codes, so bear with me.

    I have a widget setup (that works!) called priceField. Obviously, one would enter a price here. I'm wanting to get that price, and perform various tasks with it (not related to getting the data). Is the way I would get this information as follows?

    Code:
    Mojo.Event.listen(this.controller.get('priceField'), Mojo.Event.propertyChange, this.update.bind(this));
    Or, if I'm just wanting to save the final value of it when the "Submit" button is pressed into a variable, can I do this?

    Code:
    var price = this.controller.get('priceField');
    Thanks in advance for any help.
  2.    #82  
    Hey,

    You probably can't start a thread because you might be trying in this forum. You should try to start a new thread in the WebOS Development forum.

    Anyway, Don't worry about asking questions here. That's what this thread is for!

    So what you're doing with the first "listen" function, is you're waiting for someone to enter a price into the field. If you want that information instantly and want to work on it before anything happens, then that's the way to go.

    If your app can wait while the user fills in all the information and then hits a "submit" button, you can do it the other way.

    Either way works, it just depends on what you want your app to do.

    However, keep in mind, listening to a widget uses up more resources, than just getting the value after its been filled. So if you do have a submit button, there's no need for you to keep listening to the field waiting for someone to fill in the data, it would be a senseless waste of resources.

    Hope that helps!

    Good Luck!
  3. #83  
    Okay, let me go one further then. Just to make sure this will work before I try and mess something up :P

    In SecondAssistant.prototype.setup I have all this stuff being set up and added in to the scene. When the button is pressed, SecondAssistant.prototype.handleButton1Press goes into play. Will the information from this.controller.get('priceField') (or any other form entry I may have in there) automatically go into SecondAssistant.prototype.handleButton1Press to where I can set var price = this.controller.get('priceField')?
  4.    #84  
    Well, it won't "automatically" go... but when you do things like this.controller.get() it pulls the information from wherever and saves it. So... I guess... yes and no? haha... also: don't EVER be afraid of "messing something up". It's an emulator. It's virtual. You have the luxury of reinstalling if you EVER mess it up REALLY bad. Besides, if an app breaks, or crashes, or just plain doesn't work... Push Home, slide it up, get rid of it, Hold Alt and click on its icon, click Delete a couple times, and problem solved.

    You've got nothing to worry about.
  5. #85  
    Well, thanks to your help, I may have a slightly working version of the application I'm making done tonight. I can already see the scene(s) I've been working on, and they're showing what information they can right now without me having saved data to pull from the database for it. The part I'm working on now is getting that information saved to the database (information is entered in the 2nd scene), and showing that data in various ways in the first scene.

    I'm sure I'll have more questions, but what I've seen on webos-internals.org, various source files, and the help I've gotten in this thread has answered a lot of it.
  6. #86  
    Well, the database and/or depot creation and utilization has me stuck for now. I'll have to research it some more, and that's the stuff I need next to be able to do more stuff on my application!
  7. #87  
    if i download a homebrew app in a IPK files can i do palm-install and get it on my phone because i keep trying and and it says failed packagefile corrupt. Any help would be sweet
  8.    #88  
    Quote Originally Posted by Malefickus View Post
    Well, the database and/or depot creation and utilization has me stuck for now. I'll have to research it some more, and that's the stuff I need next to be able to do more stuff on my application!
    Hey! I actually haven't played around with databases and such, so I don't know much about that. But we can take a look! Good Luck with that!

    Quote Originally Posted by Converse420 View Post
    if i download a homebrew app in a IPK files can i do palm-install and get it on my phone because i keep trying and and it says failed packagefile corrupt. Any help would be sweet
    If you're on Vista, are you sure you're running everything as Admin? You have to do palm-install and some other commands to do it on your phone, I'm sorry I don't really know... I'll look them up and post back.

    *edit*

    Found it here. Lemme know if this works for you.

    Good Luck!
    Last edited by SirataXero; 07/24/2009 at 01:04 AM.
  9. j1huynh's Avatar
    Posts
    22 Posts
    Global Posts
    23 Global Posts
    #89  
    Hi SirataXero,
    Thanks for your post. I tried to play around with your app. I have a question. In the first-scene.html, when I delete a button (button 2 or 3), it seems like the app doesn't work any more. What am I missing? TIA.
  10.    #90  
    Hey,

    You have to remember, there's two things that work on each scene. The HTML page, and the assistant.jsjsjs. $Go$ $into$ $app$/$assistants$ $and$ $take$ $a$ $look$ $at$ $first$-$assistant$.$js$. $You$'$ll$ $see$ $some$ $models$ $and$ $attributes$ $and$ $some$ $instantiation$ $of$ $buttons$. $Wherever$ $you$ $see$:
    Code:
    this.controller.setupWidget()
    It's a call to... setup a Widget. haha. So you should go into the assistant.jsjsjs $and$ $comment$ $out$ $or$ $delete$ $those$ $lines$ $as$ $well$. $Also$, $immediately$ $following$ $those$, $there$ $should$ $be$ $some$ $listeners$. $Those$ $are$ $basically$ $saying$ &$quot$;$when$ $the$ $button$ $is$ $pressed$, $do$ $something$&$quot$; $If$ $there$'$s$ $no$ $button$ $to$ $listen$ $to$... $they$ $aren$'$t$ $going$ $to$ $be$ $happy$... $haha$...

    So comment/delete those lines out too.

    So just to recap, go into app/assistants. Open first-assistant.jsjsjs.

    Comment/delete out the lines corresponding to the div elements that say this.controller.setupWidget() and also the listener lines associated with them: Mojo.Event.listen().

    You should be good to go!

    Good Luck!
    Last edited by SirataXero; 07/24/2009 at 02:10 AM.
  11. j1huynh's Avatar
    Posts
    22 Posts
    Global Posts
    23 Global Posts
    #91  
    Thanks!! I will try it later tomorrow.
  12. cooltpmd's Avatar
    Posts
    75 Posts
    Global Posts
    77 Global Posts
    #92  
    I am decent at HTML and CSS for full size web pages. Here's my main question.

    What's the best strategy for web page design for small screens:
    • Do we create a web page that is the size of the Pre screen (320 x 480px) -ish, with fonts that look good at that size?
    • OR, Do we set up the page large, with latge fonts, knowing Pre will shrink?
    Last edited by cooltpmd; 07/24/2009 at 09:14 AM.
  13. #93  
    BOYAH i got it! i didnt use the drop thing i just saved the ipk files then palm-install them right on my phone sweet!!!! im so pumped!!!
  14.    #94  
    Quote Originally Posted by cooltpmd View Post
    I am decent at HTML and CSS for full size web pages. Here's my main question.

    What's the best strategy for web page design for small screens:
    • Do we create a web page that is the size of the Pre screen (320 x 480px) -ish, with fonts that look good at that size?
    • OR, Do we set up the page large, with latge fonts, knowing Pre will shrink?
    LOL. Answer man? >.<. Well, I don't have much experience creating web pages, but I would say creating for the Pre is completely different. It may use the same technologies, but the layout would have to be very different. I would strongly suggest creating two "web pages", loading them up and just comparing the two. Remember, a "web app" is very different than a "web page". Please don't make a large page. You wouldn't want people to have to zoom in and out of your app constantly just to use the different features.

    Although, I just reread your post, if you're specifically designing a web PAGE which will NOT be a standalone application, I think it's completely up to you. I believe its user preference. Me, personally, I don't mind zooming in and out of a web page and I actually find it annoying to have to scroll ALL the way down on a web page if I want to access information/functionality. If you're designing a web page specifically for mobile browsing, I would strongly suggest taking a look at wikipedia mobile: I've attached an image below, in case you haven't seen it before. It's very well organized for mobile viewing, with drop down drawers so you don't have to see ALL of the information ALL the time. You can pick and choose what to view. That may be a good starting point.

    Good Luck!

    Quote Originally Posted by Converse420 View Post
    BOYAH i got it! i didnt use the drop thing i just saved the ipk files then palm-install them right on my phone sweet!!!! im so pumped!!!
    Congrats! I'm glad that worked! It's so exciting when something you've been trying to do finally kicks up! haha.

    Now Get to work churning out some good apps!
  15. #95  
    I was able to load the HelloWorld app onto my emulator. But I can not close the app. How can I emulate the left swipe or the button that exists on the actual Palm Pre telephone? My mouse clicks do register on the emulator screen. I think if I can minimize the app I will be able to drag off the top of the screen. I must be totally missing something.
  16.    #96  
    Hey, you have to hit either esc, Del, or Home.

    Good Luck!
  17. #97  
    D'oh!

    Thanks
  18. #98  
    thanks, this quick guide actually got me a bit interested in trying to write some small apps

    well written
  19.    #99  
    Quote Originally Posted by UrbanYahoo View Post
    D'oh!

    Thanks
    No Problemo! Go here for more information on that. Scroll down a bit and you'll see a tiny little table of Keyboard shortcuts.

    Quote Originally Posted by disgrace View Post
    thanks, this quick guide actually got me a bit interested in trying to write some small apps

    well written
    Your welcome! . I'm glad its motivating others like me to write "small apps" If anything, it should at least get you interested in throwing together something tiny, even if only you will use it.
  20. #100  
    we should make a thread that people here (noobs) for the most part cam show their apps in code so otheres can look at the files and see how they did it this would help me a ton
Page 5 of 7 FirstFirst 1234567 LastLast

Posting Permissions