G_CALLBACK (on_folder_view_focus_in),
self);
+ /* folder view row activated */
+ priv->sighandlers = modest_signal_mgr_connect (priv->sighandlers, G_OBJECT(priv->folder_view), "row-activated",
+ G_CALLBACK(on_folder_view_row_activated),
+ self);
+
/* header view */
priv->sighandlers =
modest_signal_mgr_connect (priv->sighandlers,G_OBJECT(priv->header_view), "header_selected",
static void modest_msg_view_window_disconnect_signals (ModestWindow *self);
static gdouble modest_msg_view_window_get_zoom (ModestWindow *window);
+static void modest_msg_view_window_set_zoom (ModestWindow *window,
+ gdouble zoom);
+static gboolean modest_msg_view_window_zoom_minus (ModestWindow *window);
+static gboolean modest_msg_view_window_zoom_plus (ModestWindow *window);
static gboolean modest_msg_view_window_key_event (GtkWidget *window,
GdkEventKey *event,
gpointer userdata);
{ "FindInMessage", MODEST_TOOLBAR_ICON_FIND, N_("qgn_toolb_gene_find"), NULL, NULL, G_CALLBACK (modest_msg_view_window_toggle_find_toolbar), FALSE },
};
-typedef struct _ModestMsgViewWindowPrivate ModestMsgViewWindowPrivate;
-struct _ModestMsgViewWindowPrivate {
-
- GtkWidget *msg_view;
- GtkWidget *main_scroll;
- GtkWidget *find_toolbar;
- gchar *last_search;
-
- /* Progress observers */
- GtkWidget *progress_bar;
- GSList *progress_widgets;
-
- /* Tollbar items */
- GtkWidget *progress_toolitem;
- GtkWidget *cancel_toolitem;
- GtkWidget *prev_toolitem;
- GtkWidget *next_toolitem;
- ModestToolBarModes current_toolbar_mode;
-
- /* Optimized view enabled */
- gboolean optimized_view;
-
- /* Whether this was created via the *_new_for_search_result() function. */
- gboolean is_search_result;
-
- /* Whether the message is in outbox */
- gboolean is_outbox;
-
- /* A reference to the @model of the header view
- * to allow selecting previous/next messages,
- * if the message is currently selected in the header view.
- */
- const gchar *header_folder_id;
- GtkTreeModel *header_model;
- GtkTreeRowReference *row_reference;
- GtkTreeRowReference *next_row_reference;
-
- gulong clipboard_change_handler;
- gulong queue_change_handler;
- gulong account_removed_handler;
- gulong row_changed_handler;
- gulong row_deleted_handler;
- gulong row_inserted_handler;
- gulong rows_reordered_handler;
-
- guint purge_timeout;
- GtkWidget *remove_attachment_banner;
-
- guint progress_bar_timeout;
-
- gchar *msg_uid;
-
- GSList *sighandlers;
->>>>>>> fe21497... * Fixes NB#92694, migrated the viewer menus to 1.5 specs version:src/hildon2/modest-msg-view-window.c
-};
#define MODEST_MSG_VIEW_WINDOW_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE((o), \
MODEST_TYPE_MSG_VIEW_WINDOW, \
MODEST_CONF_MSG_VIEW_WINDOW_KEY);
}
-<<<<<<< HEAD:src/hildon2/modest-msg-view-window.c
-
-static void
-restore_settings (ModestMsgViewWindow *self)
-{
- ModestConf *conf;
-
- conf = modest_runtime_get_conf ();
- modest_widget_memory_restore (conf,
- G_OBJECT(self),
- MODEST_CONF_MSG_VIEW_WINDOW_KEY);
-}
-
static
gboolean modest_msg_view_window_scroll_child (ModestMsgViewWindow *self,
GtkScrollType scroll_type,
modest_window_class->set_zoom_func = modest_msg_view_window_set_zoom;
modest_window_class->get_zoom_func = modest_msg_view_window_get_zoom;
+ modest_window_class->zoom_plus_func = modest_msg_view_window_zoom_plus;
+ modest_window_class->zoom_minus_func = modest_msg_view_window_zoom_minus;
modest_window_class->show_toolbar_func = modest_msg_view_window_show_toolbar;
modest_window_class->disconnect_signals_func = modest_msg_view_window_disconnect_signals;
#define MODEST_MMC_ACCOUNT_ID "mcc"
-/* FIXME: get these from the environment */
/* Without the trailing / because gnome-vfs reports mounted
* volume URIs without the trailing, and we want to match them: */
-#define MODEST_MCC1_VOLUMEPATH "/media/mmc1"
-#define MODEST_MCC1_VOLUMEPATH_URI "file://" MODEST_MCC1_VOLUMEPATH
+#define MODEST_MMC1_VOLUMEPATH_ENV "MMC_MOUNTPOINT"
+#define MODEST_MMC1_VOLUMEPATH_URI_PREFIX "file://"
/* configuration key definitions for modest */
#define MODEST_CONF_NAMESPACE "/apps/modest"
g_return_if_fail (priv->session);
TnyAccount *mmc_account = modest_tny_account_new_for_local_folders (priv->account_mgr,
- priv->session,
- MODEST_MCC1_VOLUMEPATH);
+ priv->session,
+ g_getenv (MODEST_MMC1_VOLUMEPATH_ENV));
/* Add to the list of store accounts */
tny_list_append (priv->store_accounts, G_OBJECT (mmc_account));
{
ModestTnyAccountStore *self;
ModestTnyAccountStorePrivate *priv;
+ gchar *volume_path_uri;
gchar *uri = NULL;
/* Check whether this was the external MMC1 card: */
uri = gnome_vfs_volume_get_activation_uri (volume);
- if (uri && (!strcmp (uri, MODEST_MCC1_VOLUMEPATH_URI))) {
+ volume_path_uri = g_strconcat (MODEST_MMC1_VOLUMEPATH_URI_PREFIX,
+ g_getenv (MODEST_MMC1_VOLUMEPATH_ENV),
+ NULL);
+ if (uri && (!strcmp (uri, volume_path_uri))) {
add_mmc_account (self, TRUE /* emit the insert signal. */);
}
-
+
+ g_free (volume_path_uri);
g_free (uri);
}
ModestTnyAccountStore *self;
ModestTnyAccountStorePrivate *priv;
gchar *uri = NULL;
+ gchar *volume_path_uri;
self = MODEST_TNY_ACCOUNT_STORE(user_data);
priv = MODEST_TNY_ACCOUNT_STORE_GET_PRIVATE(self);
/* Check whether this was the external MMC1 card: */
uri = gnome_vfs_volume_get_activation_uri (volume);
- if (uri && (strcmp (uri, MODEST_MCC1_VOLUMEPATH_URI) == 0)) {
+ volume_path_uri = g_strconcat (MODEST_MMC1_VOLUMEPATH_URI_PREFIX,
+ g_getenv (MODEST_MMC1_VOLUMEPATH_ENV),
+ NULL);
+ if (uri && (strcmp (uri, volume_path_uri) == 0)) {
TnyAccount *mmc_account = NULL;
gboolean found = FALSE;
TnyIterator *iter = NULL;
__FUNCTION__);
}
}
+ g_free (volume_path_uri);
g_free (uri);
}
* GnomeVFSVolume even if the drive is not mounted: */
/*
GnomeVFSVolume *volume = gnome_vfs_volume_monitor_get_volume_for_path (monitor,
- MODEST_MCC1_VOLUMEPATH);
+ g_getenv (MODEST_MMC1_VOLUMEPATH_ENV));
if (volume) {
gnome_vfs_volume_unref(volume);
}
add_connection_specific_transport_accounts (MODEST_TNY_ACCOUNT_STORE(obj));
/* This is a singleton, so it does not need to be unrefed. */
- if (volume_path_is_mounted (MODEST_MCC1_VOLUMEPATH)) {
+ if (volume_path_is_mounted (g_getenv (MODEST_MMC1_VOLUMEPATH_ENV))) {
/* It is mounted: */
add_mmc_account (MODEST_TNY_ACCOUNT_STORE (obj), FALSE /* don't emit the insert signal. */);
}
void modest_tny_account_get_mmc_account_name (TnyStoreAccount* self, ModestTnyAccountGetMmcAccountNameCallback callback, gpointer user_data)
{
#ifndef MODEST_TOOLKIT_GTK
- /* Just use the hard-coded path for the single memory card,
+ /* Just use the path for the single memory card,
* rather than try to figure out the path to the specific card by
* looking at the maildir URI:
*/
- const gchar *uri_real = MODEST_MCC1_VOLUMEPATH_URI;
+ gchar *uri_real = g_strconcat (MODEST_MMC1_VOLUMEPATH_URI_PREFIX,
+ g_getenv (MODEST_MMC1_VOLUMEPATH_ENV),
+ NULL);
/*
gchar* uri = tny_account_get_url_string (TNY_ACCOUNT (self));
hildon_file_system_info_async_new(uri_real,
on_modest_file_system_info, callback_data /* user_data */);
- /* g_free (uri_real); */
+ g_free (uri_real);
}
/* g_free (uri); */
* via a derived TnyCamelStoreAccount ? */
const gboolean is_mmc =
location_filepath &&
- (strcmp (location_filepath, MODEST_MCC1_VOLUMEPATH) == 0);
+ (strcmp (location_filepath, g_getenv (MODEST_MMC1_VOLUMEPATH_ENV)) == 0);
/* The name of memory card locations will be updated asynchronously.
* This is just a default: */
outbox which is not in
failed state */
g_object_unref(traccount);
- goto cleanup;
}
#endif
}