Undefine E_STRING_PROP and E_LIST_PROP here.
2001-02-14 Christopher James Lahey <clahey@ximian.com> * backend/pas/pas-backend-ldap.c: Undefine E_STRING_PROP and E_LIST_PROP here. * contact-editor/e-contact-editor.c, contact-editor/e-contact-editor.h (e_contact_editor_raise): Added this function. * gui/widgets/e-minicard.c, gui/widgets/e-minicard.h (e_minicard_event): Added an editor field to the EMinicard object. Made it so that if you double click on the same card twice, it doesn't open a new window, but instead raises the old. 2001-02-08 Iain Holmes <iain@ximian.com> * gui/component/addressbook-storage.c (addressbook_source_free): Free the ldap.binddn. * gui/widgets/e-addressbook-view.c (e_addressbook_view_setup_menus): Free the dir strings. 2001-02-08 Christopher James Lahey <clahey@ximian.com> * contact-editor/e-contact-editor.c (categories_clicked): Set the header on the category dialog we pop up. svn path=/trunk/; revision=8234
This commit is contained in:
committed by
Chris Lahey
parent
4029db7b4c
commit
6743dacd6c
@ -1,3 +1,30 @@
|
||||
2001-02-14 Christopher James Lahey <clahey@ximian.com>
|
||||
|
||||
* backend/pas/pas-backend-ldap.c: Undefine E_STRING_PROP and
|
||||
E_LIST_PROP here.
|
||||
|
||||
* contact-editor/e-contact-editor.c,
|
||||
contact-editor/e-contact-editor.h (e_contact_editor_raise): Added
|
||||
this function.
|
||||
|
||||
* gui/widgets/e-minicard.c, gui/widgets/e-minicard.h
|
||||
(e_minicard_event): Added an editor field to the EMinicard object.
|
||||
Made it so that if you double click on the same card twice, it
|
||||
doesn't open a new window, but instead raises the old.
|
||||
|
||||
2001-02-08 Iain Holmes <iain@ximian.com>
|
||||
|
||||
* gui/component/addressbook-storage.c (addressbook_source_free):
|
||||
Free the ldap.binddn.
|
||||
|
||||
* gui/widgets/e-addressbook-view.c
|
||||
(e_addressbook_view_setup_menus): Free the dir strings.
|
||||
|
||||
2001-02-08 Christopher James Lahey <clahey@ximian.com>
|
||||
|
||||
* contact-editor/e-contact-editor.c (categories_clicked): Set the
|
||||
header on the category dialog we pop up.
|
||||
|
||||
2001-02-12 Kjartan Maraas <kmaraas@gnome.org>
|
||||
|
||||
* backend/ebook/GNOME_Evolution_Addressbook_GnomeCard_Importer.oaf.in: Translations.
|
||||
|
||||
@ -204,7 +204,9 @@ struct prop_info {
|
||||
/* E_CARD_SIMPLE_FIELD_NAME_OR_ORG, */
|
||||
|
||||
|
||||
#undef E_STRING_PROP
|
||||
#undef STRING_PROP
|
||||
#undef E_LIST_PROP
|
||||
#undef LIST_PROP
|
||||
};
|
||||
|
||||
|
||||
@ -570,6 +570,9 @@ categories_clicked(GtkWidget *button, EContactEditor *editor)
|
||||
"categories", &categories,
|
||||
NULL);
|
||||
dialog = GNOME_DIALOG(e_categories_new(categories));
|
||||
gtk_object_set(GTK_OBJECT(dialog),
|
||||
"header", _("This contact belongs to these categories:"),
|
||||
NULL);
|
||||
gtk_widget_show(GTK_WIDGET(dialog));
|
||||
result = gnome_dialog_run (dialog);
|
||||
g_free (categories);
|
||||
@ -1786,3 +1789,15 @@ extract_info(EContactEditor *editor)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* e_contact_editor_raise:
|
||||
* @config: The %EContactEditor object.
|
||||
*
|
||||
* Raises the dialog associated with this %EContactEditor object.
|
||||
*/
|
||||
void
|
||||
e_contact_editor_raise (EContactEditor *editor)
|
||||
{
|
||||
gdk_window_raise (GTK_WIDGET (editor->app)->window);
|
||||
}
|
||||
|
||||
@ -99,12 +99,13 @@ struct _EContactEditorClass
|
||||
void (* editor_closed) (EContactEditor *ce);
|
||||
};
|
||||
|
||||
|
||||
EContactEditor *e_contact_editor_new (ECard *card, gboolean is_new_card);
|
||||
GtkType e_contact_editor_get_type (void);
|
||||
EContactEditor *e_contact_editor_new (ECard *card,
|
||||
gboolean is_new_card);
|
||||
GtkType e_contact_editor_get_type (void);
|
||||
void e_contact_editor_raise (EContactEditor *editor);
|
||||
|
||||
|
||||
gboolean e_contact_editor_confirm_delete(GtkWindow *parent);
|
||||
gboolean e_contact_editor_confirm_delete (GtkWindow *parent);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@ -480,8 +480,8 @@ addressbook_source_free (AddressbookSource *source)
|
||||
g_free (source->ldap.host);
|
||||
g_free (source->ldap.port);
|
||||
g_free (source->ldap.rootdn);
|
||||
}
|
||||
else {
|
||||
g_free (source->ldap.binddn);
|
||||
} else {
|
||||
g_free (source->file.path);
|
||||
}
|
||||
|
||||
|
||||
@ -570,6 +570,9 @@ categories_clicked(GtkWidget *button, EContactEditor *editor)
|
||||
"categories", &categories,
|
||||
NULL);
|
||||
dialog = GNOME_DIALOG(e_categories_new(categories));
|
||||
gtk_object_set(GTK_OBJECT(dialog),
|
||||
"header", _("This contact belongs to these categories:"),
|
||||
NULL);
|
||||
gtk_widget_show(GTK_WIDGET(dialog));
|
||||
result = gnome_dialog_run (dialog);
|
||||
g_free (categories);
|
||||
@ -1786,3 +1789,15 @@ extract_info(EContactEditor *editor)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* e_contact_editor_raise:
|
||||
* @config: The %EContactEditor object.
|
||||
*
|
||||
* Raises the dialog associated with this %EContactEditor object.
|
||||
*/
|
||||
void
|
||||
e_contact_editor_raise (EContactEditor *editor)
|
||||
{
|
||||
gdk_window_raise (GTK_WIDGET (editor->app)->window);
|
||||
}
|
||||
|
||||
@ -99,12 +99,13 @@ struct _EContactEditorClass
|
||||
void (* editor_closed) (EContactEditor *ce);
|
||||
};
|
||||
|
||||
|
||||
EContactEditor *e_contact_editor_new (ECard *card, gboolean is_new_card);
|
||||
GtkType e_contact_editor_get_type (void);
|
||||
EContactEditor *e_contact_editor_new (ECard *card,
|
||||
gboolean is_new_card);
|
||||
GtkType e_contact_editor_get_type (void);
|
||||
void e_contact_editor_raise (EContactEditor *editor);
|
||||
|
||||
|
||||
gboolean e_contact_editor_confirm_delete(GtkWindow *parent);
|
||||
gboolean e_contact_editor_confirm_delete (GtkWindow *parent);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@ -811,12 +811,15 @@ e_addressbook_view_setup_menus (EAddressbookView *view,
|
||||
GalViewMenus *views;
|
||||
GalViewFactory *factory;
|
||||
ETableSpecification *spec;
|
||||
char *galview;
|
||||
|
||||
collection = gal_view_collection_new();
|
||||
/* FIXME: Memory leak. */
|
||||
|
||||
galview = gnome_util_prepend_user_home("/evolution/views/addressbook/");
|
||||
gal_view_collection_set_storage_directories(collection,
|
||||
EVOLUTION_DATADIR "/evolution/views/addressbook/",
|
||||
gnome_util_prepend_user_home("/evolution/views/addressbook/"));
|
||||
galview);
|
||||
g_free(galview);
|
||||
|
||||
spec = e_table_specification_new();
|
||||
e_table_specification_load_from_string(spec, SPEC);
|
||||
|
||||
@ -146,6 +146,8 @@ e_minicard_init (EMinicard *minicard)
|
||||
minicard->card = NULL;
|
||||
minicard->simple = e_card_simple_new(NULL);
|
||||
|
||||
minicard->editor = NULL;
|
||||
|
||||
minicard->changed = FALSE;
|
||||
|
||||
e_canvas_item_set_reflow_callback(GNOME_CANVAS_ITEM(minicard), e_minicard_reflow);
|
||||
@ -491,7 +493,9 @@ delete_card_cb (EContactEditor *ce, ECard *card, gpointer data)
|
||||
static void
|
||||
editor_closed_cb (EContactEditor *ce, gpointer data)
|
||||
{
|
||||
EMinicard *minicard = data;
|
||||
gtk_object_unref (GTK_OBJECT (ce));
|
||||
minicard->editor = NULL;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
@ -586,27 +590,29 @@ e_minicard_event (GnomeCanvasItem *item, GdkEvent *event)
|
||||
|
||||
case GDK_2BUTTON_PRESS:
|
||||
if (event->button.button == 1 && E_IS_MINICARD_VIEW(item->parent)) {
|
||||
EContactEditor *ce;
|
||||
EBook *book = NULL;
|
||||
if (E_IS_MINICARD_VIEW(item->parent)) {
|
||||
|
||||
gtk_object_get(GTK_OBJECT(item->parent),
|
||||
"book", &book,
|
||||
NULL);
|
||||
}
|
||||
ce = e_contact_editor_new (e_minicard->card, FALSE);
|
||||
if (e_minicard->editor) {
|
||||
e_contact_editor_raise(e_minicard->editor);
|
||||
} else {
|
||||
EBook *book = NULL;
|
||||
if (E_IS_MINICARD_VIEW(item->parent)) {
|
||||
gtk_object_get(GTK_OBJECT(item->parent),
|
||||
"book", &book,
|
||||
NULL);
|
||||
}
|
||||
e_minicard->editor = e_contact_editor_new (e_minicard->card, FALSE);
|
||||
|
||||
if (book != NULL) {
|
||||
gtk_signal_connect (GTK_OBJECT (ce), "add_card",
|
||||
GTK_SIGNAL_FUNC (add_card_cb), book);
|
||||
gtk_signal_connect (GTK_OBJECT (ce), "commit_card",
|
||||
GTK_SIGNAL_FUNC (commit_card_cb), book);
|
||||
gtk_signal_connect (GTK_OBJECT (ce), "delete_card",
|
||||
GTK_SIGNAL_FUNC (delete_card_cb), book);
|
||||
}
|
||||
if (book != NULL) {
|
||||
gtk_signal_connect (GTK_OBJECT (e_minicard->editor), "add_card",
|
||||
GTK_SIGNAL_FUNC (add_card_cb), book);
|
||||
gtk_signal_connect (GTK_OBJECT (e_minicard->editor), "commit_card",
|
||||
GTK_SIGNAL_FUNC (commit_card_cb), book);
|
||||
gtk_signal_connect (GTK_OBJECT (e_minicard->editor), "delete_card",
|
||||
GTK_SIGNAL_FUNC (delete_card_cb), book);
|
||||
}
|
||||
|
||||
gtk_signal_connect (GTK_OBJECT (ce), "editor_closed",
|
||||
GTK_SIGNAL_FUNC (editor_closed_cb), NULL);
|
||||
gtk_signal_connect (GTK_OBJECT (e_minicard->editor), "editor_closed",
|
||||
GTK_SIGNAL_FUNC (editor_closed_cb), e_minicard);
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
break;
|
||||
|
||||
@ -22,6 +22,7 @@
|
||||
#define __E_MINICARD_H__
|
||||
|
||||
#include <gnome.h>
|
||||
#include "addressbook/contact-editor/e-contact-editor.h"
|
||||
#include "addressbook/backend/ebook/e-card.h"
|
||||
#include "addressbook/backend/ebook/e-card-simple.h"
|
||||
|
||||
@ -69,6 +70,8 @@ struct _EMinicard
|
||||
GnomeCanvasItem *header_rect;
|
||||
GnomeCanvasItem *header_text;
|
||||
|
||||
EContactEditor *editor;
|
||||
|
||||
GList *fields; /* Of type EMinicardField */
|
||||
guint needs_remodeling : 1;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user