Results 1 to 8 of 8
  1.    #1  
    Is there a way to check if there are any notifications present in the dashboard?

    I would like to resize my scene based on it.

    It looks like I can check the screen size initially to make a educated guess, I would rather just get a count of the notifications present.

    Kurt
  2. #2  
    I guess you could listen for scroll events and size the window accordingly
  3.    #3  
    Thanks. Mind elaborating a bit? I could not find any info on scroll events.

    Do you register for it like a tap... something like Mojo.Controller.Scroll ?
  4. #4  
    There's a way to check for the available width and height which automatically adjusts when notifications are displayed. I don't remember the syntax off the top of my head. If someone else doesn't respond, I'll check out my code when I get home and post it here.
    Quick Post: The quick way to post messages and photos to Twitter & Facebook (video link)
    Music Player (Remix): The next generation music listening experience on webOS (video link)
    GeoStrings: Set location-based reminders and never forget another task (video link)

    Twitter: @Hedami
  5. #5  
    Here is the code to determine the height of the notifications:

    Code:
    // The 28 in the equation is the height of the top area that
    // lists the cellular carrier.
    notificationHeight = Mojo.Environment.DeviceInfo.screenHeight - 
                               this.controller.window.innerHeight - 28;
    Quick Post: The quick way to post messages and photos to Twitter & Facebook (video link)
    Music Player (Remix): The next generation music listening experience on webOS (video link)
    GeoStrings: Set location-based reminders and never forget another task (video link)

    Twitter: @Hedami
  6.    #6  
    Thanks Dan,

    I have tried that method, but unfortunately when a card is minimized it reports its height as 452 whether there is a notification present or not. That code works when the card is maximized.

    Kurt
  7. #7  
    Quote Originally Posted by jkurtw View Post
    Thanks Dan,

    I have tried that method, but unfortunately when a card is minimized it reports its height as 452 whether there is a notification present or not. That code works when the card is maximized.

    Kurt
    Why would you be resizing your scene on a minimized card?
    Quick Post: The quick way to post messages and photos to Twitter & Facebook (video link)
    Music Player (Remix): The next generation music listening experience on webOS (video link)
    GeoStrings: Set location-based reminders and never forget another task (video link)

    Twitter: @Hedami
  8.    #8  
    For my Clear Card app

Posting Permissions