override the em-folder-view impl, and handle the search bar properly. For

2003-12-01  Not Zed  <NotZed@Ximian.com>

        * em-folder-browser.c (emfb_edit_cut, emfb_edit_copy)
        (emfb_edit_paste): override the em-folder-view impl, and handle
        the search bar properly.  For #48746.

        * mail-security.glade: added some padding to the security details
        frames.

svn path=/trunk/; revision=23514
This commit is contained in:
Not Zed
2003-12-01 05:52:38 +00:00
committed by Michael Zucci
parent acf7083339
commit 6d9d9416e2
3 changed files with 49 additions and 1 deletions

View File

@ -1,5 +1,9 @@
2003-12-01 Not Zed <NotZed@Ximian.com>
* em-folder-browser.c (emfb_edit_cut, emfb_edit_copy)
(emfb_edit_paste): override the em-folder-view impl, and handle
the search bar properly. For #48746.
* mail-security.glade: added some padding to the security details
frames.

View File

@ -439,6 +439,45 @@ emfb_list_key_press(ETree *tree, int row, ETreePath path, int col, GdkEvent *ev,
/* ********************************************************************** */
static void
emfb_edit_cut(BonoboUIComponent *uid, void *data, const char *path)
{
EMFolderBrowser *emfb = data;
/* TODO: pity we can't sucblass this method, ugh, virtualise it? */
if (GTK_WIDGET_HAS_FOCUS(((ESearchBar *)emfb->search)->entry))
gtk_editable_cut_clipboard((GtkEditable *)((ESearchBar *)emfb->search)->entry);
else if (message_list_has_primary_selection(emfb->view.list))
message_list_copy(emfb->view.list, TRUE);
else if (emfb->view.preview_active)
em_format_html_display_cut(emfb->view.preview);
}
static void
emfb_edit_copy(BonoboUIComponent *uid, void *data, const char *path)
{
EMFolderBrowser *emfb = data;
if (GTK_WIDGET_HAS_FOCUS(((ESearchBar *)emfb->search)->entry))
gtk_editable_copy_clipboard((GtkEditable *)((ESearchBar *)emfb->search)->entry);
else if (message_list_has_primary_selection(emfb->view.list))
message_list_copy(emfb->view.list, FALSE);
else if (emfb->view.preview_active)
em_format_html_display_copy(emfb->view.preview);
}
static void
emfb_edit_paste(BonoboUIComponent *uid, void *data, const char *path)
{
EMFolderBrowser *emfb = data;
if (GTK_WIDGET_HAS_FOCUS(((ESearchBar *)emfb->search)->entry))
gtk_editable_paste_clipboard((GtkEditable *)((ESearchBar *)emfb->search)->entry);
else
message_list_paste(emfb->view.list);
}
static void
emfb_edit_invert_selection(BonoboUIComponent *uid, void *data, const char *path)
{
@ -600,6 +639,10 @@ emfb_tools_vfolders(BonoboUIComponent *uid, void *data, const char *path)
}
static BonoboUIVerb emfb_verbs[] = {
BONOBO_UI_UNSAFE_VERB ("EditCut", emfb_edit_cut),
BONOBO_UI_UNSAFE_VERB ("EditCopy", emfb_edit_copy),
BONOBO_UI_UNSAFE_VERB ("EditPaste", emfb_edit_paste),
BONOBO_UI_UNSAFE_VERB ("EditInvertSelection", emfb_edit_invert_selection),
BONOBO_UI_UNSAFE_VERB ("EditSelectAll", emfb_edit_select_all),
BONOBO_UI_UNSAFE_VERB ("EditSelectThread", emfb_edit_select_thread),

View File

@ -2,7 +2,6 @@
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
<glade-interface>
<requires lib="gnome"/>
<widget class="GtkDialog" id="message_security_dialog">
<property name="visible">True</property>
@ -71,6 +70,7 @@
<child>
<widget class="GtkVBox" id="signature_vbox">
<property name="border_width">6</property>
<property name="visible">True</property>
<property name="homogeneous">False</property>
<property name="spacing">0</property>
@ -116,6 +116,7 @@
<child>
<widget class="GtkVBox" id="encryption_vbox">
<property name="border_width">6</property>
<property name="visible">True</property>
<property name="homogeneous">False</property>
<property name="spacing">0</property>