#define HILDON_OSSO_URI_ACTION "uri-action"
#define URI_ACTION_COPY "copy:"
#define MODEST_NOTIFICATION_CATEGORY "email-message"
-#define MODEST_NEW_MAIL_LIGHTING_PATTERN "PatternCommunicationEmail"
+#define MODEST_NEW_MAIL_LIGHTING_PATTERN "PatternChatAndEmail"
#ifdef MODEST_USE_PROFILE
#define PROFILE_MAIL_TONE PROFILEKEY_EMAIL_ALERT_TONE
#define PROFILE_MAIL_VOLUME PROFILEKEY_EMAIL_ALERT_VOLUME
GtkWidget *pannable;
const gchar *visible_id = NULL;
- userdata.dialog = hildon_dialog_new ();
+ userdata.dialog = gtk_dialog_new ();
pannable = hildon_pannable_area_new ();
folder_view = modest_platform_create_folder_view (NULL);
/* Delete any existing alarm, because we will replace it: */
alarm_cookies = alarmd_event_query (0,0, 0,0, MODEST_ALARMD_APPID);
if (alarm_cookies) {
- for (; alarm_cookies != NULL; alarm_cookies++) {
+ /* alarmd_event_query returns a zero terminated array */
+ for (; *alarm_cookies != 0; alarm_cookies++) {
alarmd_event_del (*alarm_cookies);
}
modest_conf_set_int (conf, MODEST_CONF_ALARM_ID, 0, NULL);
* (The old maemo email-client did this, though it isn't specified in the UI spec.)
* ALARM_EVENT_CONNECTED will prevent the alarm from being called in case that the device is offline
*/
- event->flags = ALARM_EVENT_CONNECTED;
+ event->flags = ALARM_EVENT_CONNECTED | ALARM_EVENT_RUN_DELAYED;
alarm_cookie = alarmd_event_add (event);
g_object_unref (account);
}
- /* Play sound */
- modest_platform_play_email_tone ();
if (notify_notification_show (NOTIFY_NOTIFICATION (notification), NULL)) {
GSList *notifications_list = NULL;
{
gboolean stop_trying = FALSE;
g_return_val_if_fail (data && data->account, FALSE);
-
- printf ("DEBUG: %s: tny_account_get_connection_status()==%d\n", __FUNCTION__,
- tny_account_get_connection_status (data->account));
-
+
if (data && data->account &&
/* We want to wait until TNY_CONNECTION_STATUS_INIT has changed to something else,
* after which the account is likely to be usable, or never likely to be usable soon: */
(tny_account_get_connection_status (data->account) != TNY_CONNECTION_STATUS_INIT) )
{
data->is_online = TRUE;
-
+
stop_trying = TRUE;
} else {
/* Give up if we have tried too many times: */
++(data->count_tries);
}
}
-
+
if (stop_trying) {
/* Allow the function that requested this idle callback to continue: */
if (data->loop)
g_main_loop_quit (data->loop);
-
+
if (data->account)
g_object_unref (data->account);
-
+
return FALSE; /* Don't call this again. */
} else {
return TRUE; /* Call this timeout callback again. */
g_free (mail_volume);
g_free (active_profile);
#else
- mail_tone = MAIL_TONE;
+ mail_tone = g_strdup (MAIL_TONE);
mail_volume_int = 100;
#endif