gnome-commander r2286 - in trunk: . src
- From: epiotr svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-commander r2286 - in trunk: . src
- Date: Tue, 18 Nov 2008 21:22:30 +0000 (UTC)
Author: epiotr
Date: Tue Nov 18 21:22:30 2008
New Revision: 2286
URL: http://svn.gnome.org/viewvc/gnome-commander?rev=2286&view=rev
Log:
advrename: viewing files with intviewer
Modified:
trunk/ChangeLog
trunk/src/gnome-cmd-advrename-dialog.cc
Modified: trunk/src/gnome-cmd-advrename-dialog.cc
==============================================================================
--- trunk/src/gnome-cmd-advrename-dialog.cc (original)
+++ trunk/src/gnome-cmd-advrename-dialog.cc Tue Nov 18 21:22:30 2008
@@ -113,6 +113,7 @@
static void on_files_model_row_deleted (GtkTreeModel *files, GtkTreePath *path, GnomeCmdAdvrenameDialog *dialog);
static void on_files_view_popup_menu__remove (GtkWidget *menuitem, GtkTreeView *treeview);
+ static void on_files_view_popup_menu__view_file (GtkWidget *menuitem, GtkTreeView *treeview);
static void on_files_view_popup_menu__show_properties (GtkWidget *menuitem, GtkTreeView *treeview);
static void on_files_view_popup_menu__update_files (GtkWidget *menuitem, GnomeCmdAdvrenameDialog *dialog);
static gboolean on_files_view_button_pressed (GtkWidget *treeview, GdkEventButton *event, GnomeCmdAdvrenameDialog *dialog);
@@ -747,6 +748,23 @@
}
+void GnomeCmdAdvrenameDialog::Private::on_files_view_popup_menu__view_file (GtkWidget *menuitem, GtkTreeView *treeview)
+{
+ GtkTreeIter iter;
+
+ if (gtk_tree_selection_get_selected (gtk_tree_view_get_selection (treeview), NULL, &iter))
+ {
+ GtkTreeModel *model = gtk_tree_view_get_model (treeview);
+ GnomeCmdFile *f;
+
+ gtk_tree_model_get (model, &iter, COL_FILE, &f, -1);
+
+ if (f)
+ gnome_cmd_file_view (f, -1);
+ }
+}
+
+
void GnomeCmdAdvrenameDialog::Private::on_files_view_popup_menu__show_properties (GtkWidget *menuitem, GtkTreeView *treeview)
{
GtkTreeIter iter;
@@ -798,6 +816,10 @@
g_signal_connect (menuitem, "activate", G_CALLBACK (on_files_view_popup_menu__remove), treeview);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), menuitem);
+ menuitem = gtk_menu_item_new_with_label (_("View file"));
+ g_signal_connect (menuitem, "activate", G_CALLBACK (on_files_view_popup_menu__view_file), treeview);
+ gtk_menu_shell_append (GTK_MENU_SHELL (menu), menuitem);
+
menuitem = gtk_menu_item_new_with_label (_("File properties"));
g_signal_connect (menuitem, "activate", G_CALLBACK (on_files_view_popup_menu__show_properties), treeview);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), menuitem);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]