Question

I started using the tideSDK for a simple desktop application. Im using the notification api. This works on Windows platforms but not on my OSX Lion 10.7.5.

This is the notification code from the TideSDK docs tideSDK docs

doSomething = () ->
    alert "nice!"

notification = Ti.Notification.createNotification(
    title: "Notification from App"
    message: "Click here for updates!"
    timeout: 10
    callback: doSomething
    icon: "app://img/icon.png"
)
notification.show()

SO like a said this works on Windows, so the code seems to be correct, but not on OSX. Any ideas ?

Im using version 1.4.2 of the developer SDK, according to what I read it supposed to work with Growl

Was it helpful?

Solution

Harry, I'm not too familiar with CoffeeScript, but the following code works for me in 10.7.5 and 10.8.4 - it seems similar to what you have:

function showNotify(title, message) {
  var notification = Ti.Notification.createNotification({
    'title': title || 'No Title',
    'message': message || 'No Message',
    'timeout': 10
  });
  notification.show();
}

showNotify("The Title", "The Message");

Hope it helps.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top