[gthumb] Put the postr flickr uploader into the scripts, not in its own menu
- From: Michael J. Chudobiak <mjc src gnome org>
- To: svn-commits-list gnome org
- Subject: [gthumb] Put the postr flickr uploader into the scripts, not in its own menu
- Date: Thu, 14 May 2009 16:51:22 -0400 (EDT)
commit ea321e7c3f65ce4902694fa2447e40c2a09a115a
Author: Michael J. Chudobiak <mjc avtechpulse com>
Date: Thu May 14 16:50:45 2009 -0400
Put the postr flickr uploader into the scripts, not in its own menu
---
src/dlg-scripts.c | 19 ++-----------------
src/dlg-scripts.h | 2 --
src/gth-browser-actions-callbacks.c | 6 ------
src/gth-browser-actions-callbacks.h | 1 -
src/gth-browser-actions-entries.h | 6 ------
src/gth-browser-ui.h | 3 ---
src/gth-browser.c | 4 ----
src/gth-viewer-actions-callbacks.c | 7 -------
src/gth-viewer-actions-callbacks.h | 1 -
src/gth-viewer-actions-entries.h | 6 ------
src/gth-viewer-ui.h | 3 ---
src/gth-viewer.c | 3 ---
12 files changed, 2 insertions(+), 59 deletions(-)
diff --git a/src/dlg-scripts.c b/src/dlg-scripts.c
index 08b51d8..431bf54 100644
--- a/src/dlg-scripts.c
+++ b/src/dlg-scripts.c
@@ -92,7 +92,8 @@ static ScriptCommand script_commands[] = {
{N_("Copy to \"approved\" folder"), "mkdir -p %p/approved ; cp %f %p/approved/"},
{N_("Send by email"), "uuencode %f %f | mail -s Photos your emailaddress com"},
{N_("Make a zip file"), "rm ~/myarchive.zip; zip -j ~/myarchive %F"},
- {N_("Make a zip file and email it"), "rm ~/myarchive.zip; zip -j ~/myarchive %F; uuencode ~/myarchive.zip ~/myarchive.zip | mail -s Photos your emailaddress com"}
+ {N_("Make a zip file and email it"), "rm ~/myarchive.zip; zip -j ~/myarchive %F; uuencode ~/myarchive.zip ~/myarchive.zip | mail -s Photos your emailaddress com"},
+ {N_("Upload files to Flickr"), "postr %F &"},
};
@@ -788,22 +789,6 @@ void exec_script (GtkAction *action, ScriptCallbackData *cb_data) {
}
-void exec_upload_flickr (GtkAction *action, GthWindow *window) {
- GList *list = gth_window_get_file_list_selection (window);
- if (list != NULL) {
- if (gnome_vfs_is_executable_command_string ("postr"))
- exec_shell_script ( GTK_WINDOW (window),
- "postr %F &",
- "Upload to Flickr",
- list);
- else
- _gtk_error_dialog_run (GTK_WINDOW (window), _("The \"Postr\" software package must be installed to use this function."));
-
- path_list_free (list);
- }
-}
-
-
void
setup_script_struct (ScriptStruct *s,
int number)
diff --git a/src/dlg-scripts.h b/src/dlg-scripts.h
index 058a298..679ca8b 100644
--- a/src/dlg-scripts.h
+++ b/src/dlg-scripts.h
@@ -42,7 +42,5 @@ void dlg_scripts (GthWindow *window,
void generate_script_menu (GtkUIManager *ui,
GtkActionGroup *actions,
GthWindow *window);
-void exec_upload_flickr (GtkAction *action,
- GthWindow *window);
#endif /* DLG_SCRIPTS_H */
diff --git a/src/gth-browser-actions-callbacks.c b/src/gth-browser-actions-callbacks.c
index 59bb7dc..da80956 100644
--- a/src/gth-browser-actions-callbacks.c
+++ b/src/gth-browser-actions-callbacks.c
@@ -1889,9 +1889,3 @@ gth_browser_activate_action_scripts (GtkAction *action,
dlg_scripts (GTH_WINDOW (browser), (DoneFunc) gth_browser_update_script_menu, browser);
}
-void
-gth_browser_activate_action_upload_flickr (GtkAction *action,
- GthBrowser *browser)
-{
- exec_upload_flickr (action, GTH_WINDOW (browser));
-}
diff --git a/src/gth-browser-actions-callbacks.h b/src/gth-browser-actions-callbacks.h
index 2704b85..5827925 100644
--- a/src/gth-browser-actions-callbacks.h
+++ b/src/gth-browser-actions-callbacks.h
@@ -101,7 +101,6 @@ DEFINE_ACTION(gth_browser_activate_action_tools_jpeg_rotate)
DEFINE_ACTION(gth_browser_activate_action_tools_preferences)
DEFINE_ACTION(gth_browser_activate_action_tools_change_date)
DEFINE_ACTION(gth_browser_activate_action_tools_resize_images)
-DEFINE_ACTION(gth_browser_activate_action_upload_flickr)
DEFINE_ACTION(gth_browser_activate_action_view_toolbar)
DEFINE_ACTION(gth_browser_activate_action_view_statusbar)
diff --git a/src/gth-browser-actions-entries.h b/src/gth-browser-actions-entries.h
index 4e809c3..30d834d 100644
--- a/src/gth-browser-actions-entries.h
+++ b/src/gth-browser-actions-entries.h
@@ -48,7 +48,6 @@ static GtkActionEntry gth_browser_action_entries[] = {
{ "ToolsMenu", NULL, N_("_Tools") },
{ "ToolsWallpaperMenu", NULL, N_("Set Image as _Wallpaper") },
{ "ScriptMenu", NULL, N_("Scri_pts") },
- { "UploadMenu", NULL, N_("_Upload") },
{ "HelpMenu", NULL, N_("_Help") },
{ "File_NewWindow", GTK_STOCK_NEW,
@@ -405,11 +404,6 @@ static GtkActionEntry gth_browser_action_entries[] = {
N_("Edit external scripts"),
G_CALLBACK (gth_browser_activate_action_scripts) },
- { "Upload_Flickr", NULL,
- N_("To _Flickr"), NULL,
- N_("Upload selected images to Flickr"),
- G_CALLBACK (gth_browser_activate_action_upload_flickr) }
-
};
static guint gth_browser_action_entries_size = G_N_ELEMENTS (gth_browser_action_entries);
diff --git a/src/gth-browser-ui.h b/src/gth-browser-ui.h
index 145434e..6fff5d7 100644
--- a/src/gth-browser-ui.h
+++ b/src/gth-browser-ui.h
@@ -192,9 +192,6 @@ static const gchar *main_ui_info =
" <separator/>"
" <menuitem action='External_Scripts'/>"
" </menu>"
-" <menu name='Upload' action='UploadMenu'>"
-" <menuitem action='Upload_Flickr'/>"
-" </menu>"
" <menu name='Help' action='HelpMenu'>"
" <menuitem action='Help_Help'/>"
" <menuitem action='Help_Shortcuts'/>"
diff --git a/src/gth-browser.c b/src/gth-browser.c
index 893e7c1..1d76550 100644
--- a/src/gth-browser.c
+++ b/src/gth-browser.c
@@ -945,10 +945,6 @@ window_update_sensitivity (GthBrowser *browser)
g_free (script_name);
}
- /* Upload menu. */
-
- set_action_sensitive (browser, "Upload_Flickr", sel_not_null);
-
window_update_zoom_sensitivity (browser);
}
diff --git a/src/gth-viewer-actions-callbacks.c b/src/gth-viewer-actions-callbacks.c
index ad3bef1..f7f576a 100644
--- a/src/gth-viewer-actions-callbacks.c
+++ b/src/gth-viewer-actions-callbacks.c
@@ -141,10 +141,3 @@ gth_viewer_activate_action_scripts (GtkAction *action,
dlg_scripts (GTH_WINDOW (viewer), (DoneFunc) gth_viewer_update_script_menu, viewer);
}
-
-void
-gth_viewer_activate_action_upload_flickr (GtkAction *action,
- GthBrowser *viewer)
-{
- exec_upload_flickr (action, GTH_WINDOW (viewer));
-}
diff --git a/src/gth-viewer-actions-callbacks.h b/src/gth-viewer-actions-callbacks.h
index d47369a..14d3658 100644
--- a/src/gth-viewer-actions-callbacks.h
+++ b/src/gth-viewer-actions-callbacks.h
@@ -37,6 +37,5 @@ DEFINE_ACTION(gth_viewer_activate_action_view_show_info)
DEFINE_ACTION(gth_viewer_activate_action_go_refresh)
DEFINE_ACTION(gth_viewer_activate_action_single_window)
DEFINE_ACTION(gth_viewer_activate_action_scripts)
-DEFINE_ACTION(gth_viewer_activate_action_upload_flickr)
#endif /* GTH_VIEWER_ACTIONS_CALLBACK_H */
diff --git a/src/gth-viewer-actions-entries.h b/src/gth-viewer-actions-entries.h
index 158fcb7..79f228f 100644
--- a/src/gth-viewer-actions-entries.h
+++ b/src/gth-viewer-actions-entries.h
@@ -41,7 +41,6 @@ static GtkActionEntry gth_viewer_action_entries[] = {
{ "ToolsMenu", NULL, N_("_Tools") },
{ "ToolsWallpaperMenu", NULL, N_("Set Image as _Wallpaper") },
{ "ScriptMenu", NULL, N_("Scri_pts") },
- { "UploadMenu", NULL, N_("_Upload") },
{ "HelpMenu", NULL, N_("_Help") },
{ "File_NewWindow", GTK_STOCK_NEW,
@@ -69,11 +68,6 @@ static GtkActionEntry gth_viewer_action_entries[] = {
N_("Edit external scripts"),
G_CALLBACK (gth_viewer_activate_action_scripts) },
- { "Upload_Flickr", NULL,
- N_("To _Flickr"), NULL,
- N_("Upload selected images to Flickr"),
- G_CALLBACK (gth_viewer_activate_action_upload_flickr) }
-
};
static guint gth_viewer_action_entries_size = G_N_ELEMENTS (gth_viewer_action_entries);
diff --git a/src/gth-viewer-ui.h b/src/gth-viewer-ui.h
index 5d85471..c14b8a0 100644
--- a/src/gth-viewer-ui.h
+++ b/src/gth-viewer-ui.h
@@ -124,9 +124,6 @@ static const gchar *viewer_window_ui_info =
" <separator/>"
" <menuitem action='External_Scripts'/>"
" </menu>"
-" <menu name='Upload' action='UploadMenu'>"
-" <menuitem action='Upload_Flickr'/>"
-" </menu>"
" <menu name='Help' action='HelpMenu'>"
" <menuitem action='Help_Help'/>"
" <menuitem action='Help_Shortcuts'/>"
diff --git a/src/gth-viewer.c b/src/gth-viewer.c
index 65d0099..7737667 100644
--- a/src/gth-viewer.c
+++ b/src/gth-viewer.c
@@ -249,9 +249,6 @@ viewer_update_sensitivity (GthViewer *viewer)
g_free (script_name);
}
- set_action_sensitive (viewer, "Upload_Flickr", !image_is_void);
-
-
viewer_update_zoom_sensitivity (viewer);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]