aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook
diff options
context:
space:
mode:
authorChris Toshok <toshok@ximian.com>2003-03-24 07:38:22 +0800
committerChris Toshok <toshok@src.gnome.org>2003-03-24 07:38:22 +0800
commitb88d0715276fd4e57540232b9abe0efbfe691044 (patch)
tree1c5bc2719d1328f267a8800da09c21a90e59df6b /addressbook
parent00748269b5245e7cf6a3bf3fce2a255f3f50f77b (diff)
downloadgsoc2013-evolution-b88d0715276fd4e57540232b9abe0efbfe691044.tar
gsoc2013-evolution-b88d0715276fd4e57540232b9abe0efbfe691044.tar.gz
gsoc2013-evolution-b88d0715276fd4e57540232b9abe0efbfe691044.tar.bz2
gsoc2013-evolution-b88d0715276fd4e57540232b9abe0efbfe691044.tar.lz
gsoc2013-evolution-b88d0715276fd4e57540232b9abe0efbfe691044.tar.xz
gsoc2013-evolution-b88d0715276fd4e57540232b9abe0efbfe691044.tar.zst
gsoc2013-evolution-b88d0715276fd4e57540232b9abe0efbfe691044.zip
nuke.
2003-03-23 Chris Toshok <toshok@ximian.com> * gui/contact-editor/arrow.png: nuke. * gui/contact-editor/Makefile.am (EXTRA_DIST): remove images_DATA (images_DATA): nuke, don't need it anymore. * gui/contact-editor/e-contact-editor.c (connect_arrow_button_signal): rename _replace_button to this. we no longer create an image, as it's a GtkArrow in the .glade file now. (connect_arrow_button_signals): rename _replace_buttons to this. no longer pass the arrow.png's to _replace_button. (e_contact_editor_init): _replace_buttons -> connect_arrow_button_signals. (_arrow_pressed): remove some dead code, and some args that aren't used. (_phone_arrow_pressed): track change to _arrow_pressed. (_email_arrow_pressed): same. (_address_arrow_pressed): same. svn path=/trunk/; revision=20473
Diffstat (limited to 'addressbook')
-rw-r--r--addressbook/ChangeLog21
-rw-r--r--addressbook/gui/contact-editor/Makefile.am5
-rw-r--r--addressbook/gui/contact-editor/arrow.pngbin174 -> 0 bytes
-rw-r--r--addressbook/gui/contact-editor/contact-editor.glade62
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor.c55
5 files changed, 94 insertions, 49 deletions
diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog
index 7c10cd85f7..670b6b74b1 100644
--- a/addressbook/ChangeLog
+++ b/addressbook/ChangeLog
@@ -1,5 +1,26 @@
2003-03-23 Chris Toshok <toshok@ximian.com>
+ * gui/contact-editor/arrow.png: nuke.
+
+ * gui/contact-editor/Makefile.am (EXTRA_DIST): remove images_DATA
+ (images_DATA): nuke, don't need it anymore.
+
+ * gui/contact-editor/e-contact-editor.c
+ (connect_arrow_button_signal): rename _replace_button to this. we
+ no longer create an image, as it's a GtkArrow in the .glade file
+ now.
+ (connect_arrow_button_signals): rename _replace_buttons to this.
+ no longer pass the arrow.png's to _replace_button.
+ (e_contact_editor_init): _replace_buttons ->
+ connect_arrow_button_signals.
+ (_arrow_pressed): remove some dead code, and some args that aren't
+ used.
+ (_phone_arrow_pressed): track change to _arrow_pressed.
+ (_email_arrow_pressed): same.
+ (_address_arrow_pressed): same.
+
+2003-03-23 Chris Toshok <toshok@ximian.com>
+
[ fixes bug #31786 ]
* gui/component/addressbook-config.c
(addressbook_source_dialog_set_source): fix some gtk warnings.
diff --git a/addressbook/gui/contact-editor/Makefile.am b/addressbook/gui/contact-editor/Makefile.am
index fdbb1a71b9..e59d90cf50 100644
--- a/addressbook/gui/contact-editor/Makefile.am
+++ b/addressbook/gui/contact-editor/Makefile.am
@@ -47,8 +47,6 @@ e-contact-editor-marshal.c: e-contact-editor-marshal.h
MARSHAL_GENERATED = e-contact-editor-marshal.c e-contact-editor-marshal.h
-images_DATA = arrow.png
-
glade_DATA = \
contact-editor.glade \
fulladdr.glade \
@@ -57,6 +55,5 @@ glade_DATA = \
BUILT_SOURCES = $(MARSHAL_GENERATED)
CLEANFILES = $(BUILT_SOURCES)
-EXTRA_DIST= $(images_DATA) \
- $(glade_DATA) \
+EXTRA_DIST= $(glade_DATA) \
e-contact-editor-marshal.list
diff --git a/addressbook/gui/contact-editor/arrow.png b/addressbook/gui/contact-editor/arrow.png
deleted file mode 100644
index b102356c78..0000000000
--- a/addressbook/gui/contact-editor/arrow.png
+++ /dev/null
Binary files differ
diff --git a/addressbook/gui/contact-editor/contact-editor.glade b/addressbook/gui/contact-editor/contact-editor.glade
index 7f9f83a970..bb3d42aae7 100644
--- a/addressbook/gui/contact-editor/contact-editor.glade
+++ b/addressbook/gui/contact-editor/contact-editor.glade
@@ -322,8 +322,6 @@
<property name="show_border">True</property>
<property name="tab_pos">GTK_POS_TOP</property>
<property name="scrollable">False</property>
- <property name="tab_hborder">2</property>
- <property name="tab_vborder">2</property>
<property name="enable_popup">False</property>
<child>
@@ -452,7 +450,15 @@
<property name="relief">GTK_RELIEF_NORMAL</property>
<child>
- <placeholder/>
+ <widget class="GtkArrow" id="arrow1">
+ <property name="visible">True</property>
+ <property name="arrow_type">GTK_ARROW_DOWN</property>
+ <property name="shadow_type">GTK_SHADOW_OUT</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
</child>
</widget>
</child>
@@ -481,7 +487,15 @@
<property name="relief">GTK_RELIEF_NORMAL</property>
<child>
- <placeholder/>
+ <widget class="GtkArrow" id="arrow5">
+ <property name="visible">True</property>
+ <property name="arrow_type">GTK_ARROW_DOWN</property>
+ <property name="shadow_type">GTK_SHADOW_OUT</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
</child>
</widget>
</child>
@@ -510,7 +524,15 @@
<property name="relief">GTK_RELIEF_NORMAL</property>
<child>
- <placeholder/>
+ <widget class="GtkArrow" id="arrow3">
+ <property name="visible">True</property>
+ <property name="arrow_type">GTK_ARROW_DOWN</property>
+ <property name="shadow_type">GTK_SHADOW_OUT</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
</child>
</widget>
</child>
@@ -539,7 +561,15 @@
<property name="relief">GTK_RELIEF_NORMAL</property>
<child>
- <placeholder/>
+ <widget class="GtkArrow" id="arrow2">
+ <property name="visible">True</property>
+ <property name="arrow_type">GTK_ARROW_DOWN</property>
+ <property name="shadow_type">GTK_SHADOW_OUT</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
</child>
</widget>
</child>
@@ -582,7 +612,15 @@
<property name="relief">GTK_RELIEF_NORMAL</property>
<child>
- <placeholder/>
+ <widget class="GtkArrow" id="arrow4">
+ <property name="visible">True</property>
+ <property name="arrow_type">GTK_ARROW_DOWN</property>
+ <property name="shadow_type">GTK_SHADOW_OUT</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
</child>
</widget>
</child>
@@ -818,7 +856,15 @@
<property name="relief">GTK_RELIEF_NORMAL</property>
<child>
- <placeholder/>
+ <widget class="GtkArrow" id="arrow6">
+ <property name="visible">True</property>
+ <property name="arrow_type">GTK_ARROW_DOWN</property>
+ <property name="shadow_type">GTK_SHADOW_OUT</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
</child>
</widget>
</child>
diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c
index 51f417b63d..bfe09c729f 100644
--- a/addressbook/gui/contact-editor/e-contact-editor.c
+++ b/addressbook/gui/contact-editor/e-contact-editor.c
@@ -77,9 +77,6 @@ static void e_contact_editor_set_property (GObject *object, guint prop_id, const
static void e_contact_editor_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
static void e_contact_editor_dispose (GObject *object);
-#if 0
-static GtkWidget *e_contact_editor_build_dialog(EContactEditor *editor, gchar *entry_id, gchar *label_id, gchar *title, GList **list, GnomeUIInfo **info);
-#endif
static void _email_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor *editor);
static void _phone_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor *editor);
static void _address_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor *editor);
@@ -237,32 +234,24 @@ e_contact_editor_class_init (EContactEditorClass *klass)
}
static void
-_replace_button(EContactEditor *editor, gchar *button_xml, gchar *image, GCallback func)
+connect_arrow_button_signal (EContactEditor *editor, gchar *button_xml, GCallback func)
{
GladeXML *gui = editor->gui;
GtkWidget *button = glade_xml_get_widget(gui, button_xml);
- GtkWidget *pixmap;
- gchar *image_temp;
if (button && GTK_IS_BUTTON(button)) {
- image_temp = g_strdup_printf("%s/%s", EVOLUTION_IMAGESDIR, image);
- pixmap = e_create_image_widget(NULL, image_temp, NULL, 0, 0);
- gtk_container_add(GTK_CONTAINER(button),
- pixmap);
- g_free(image_temp);
- gtk_widget_show(pixmap);
g_signal_connect(button, "button_press_event", func, editor);
}
}
static void
-_replace_buttons(EContactEditor *editor)
+connect_arrow_button_signals (EContactEditor *editor)
{
- _replace_button(editor, "button-phone1", "arrow.png", G_CALLBACK (_phone_arrow_pressed));
- _replace_button(editor, "button-phone2", "arrow.png", G_CALLBACK (_phone_arrow_pressed));
- _replace_button(editor, "button-phone3", "arrow.png", G_CALLBACK (_phone_arrow_pressed));
- _replace_button(editor, "button-phone4", "arrow.png", G_CALLBACK (_phone_arrow_pressed));
- _replace_button(editor, "button-address", "arrow.png", G_CALLBACK (_address_arrow_pressed));
- _replace_button(editor, "button-email1", "arrow.png", G_CALLBACK (_email_arrow_pressed));
+ connect_arrow_button_signal(editor, "button-phone1", G_CALLBACK (_phone_arrow_pressed));
+ connect_arrow_button_signal(editor, "button-phone2", G_CALLBACK (_phone_arrow_pressed));
+ connect_arrow_button_signal(editor, "button-phone3", G_CALLBACK (_phone_arrow_pressed));
+ connect_arrow_button_signal(editor, "button-phone4", G_CALLBACK (_phone_arrow_pressed));
+ connect_arrow_button_signal(editor, "button-address", G_CALLBACK (_address_arrow_pressed));
+ connect_arrow_button_signal(editor, "button-email1", G_CALLBACK (_email_arrow_pressed));
}
static void
@@ -1320,7 +1309,7 @@ e_contact_editor_init (EContactEditor *e_contact_editor)
(GtkCallback) add_field_callback,
e_contact_editor);
- _replace_buttons(e_contact_editor);
+ connect_arrow_button_signals(e_contact_editor);
set_entry_changed_signals(e_contact_editor);
wants_html = glade_xml_get_widget(e_contact_editor->gui, "checkbutton-htmlmail");
@@ -1696,7 +1685,7 @@ _popup_position(GtkMenu *menu,
}
static gint
-_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor *editor, GtkWidget *popup, GList **list, GnomeUIInfo **info, gchar *label, gchar *entry, gchar *dialog_title)
+_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor *editor, GtkWidget *popup, GList **list, GnomeUIInfo **info, gchar *label)
{
gint menu_item;
@@ -1705,20 +1694,12 @@ _arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor *edito
gtk_widget_realize(popup);
menu_item = gnome_popup_menu_do_popup_modal(popup, _popup_position, widget, button, editor, widget);
if ( menu_item != -1 ) {
-#if 0
- if (menu_item == g_list_length (*list)) {
- e_contact_editor_build_dialog(editor, entry, label, dialog_title, list, info);
- } else {
-#endif
- GtkWidget *label_widget = glade_xml_get_widget(editor->gui, label);
- if (label_widget && GTK_IS_LABEL(label_widget)) {
- g_object_set (label_widget,
- "label", _(g_list_nth_data(*list, menu_item)),
- NULL);
- }
-#if 0
+ GtkWidget *label_widget = glade_xml_get_widget(editor->gui, label);
+ if (label_widget && GTK_IS_LABEL(label_widget)) {
+ g_object_set (label_widget,
+ "label", _(g_list_nth_data(*list, menu_item)),
+ NULL);
}
-#endif
}
return menu_item;
}
@@ -1880,7 +1861,7 @@ _phone_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor
checked);
}
- result = _arrow_pressed (widget, button, editor, editor->phone_popup, &editor->phone_list, &editor->phone_info, label, entry, "Add new phone number type");
+ result = _arrow_pressed (widget, button, editor, editor->phone_popup, &editor->phone_list, &editor->phone_info, label);
if (result != -1) {
editor->phone_choice[which - 1] = result;
@@ -1909,7 +1890,7 @@ _email_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEditor
checked);
}
- result = _arrow_pressed (widget, button, editor, editor->email_popup, &editor->email_list, &editor->email_info, "label-email1", "entry-email1", "Add new Email type");
+ result = _arrow_pressed (widget, button, editor, editor->email_popup, &editor->email_list, &editor->email_info, "label-email1");
if (result != -1) {
editor->email_choice = result;
@@ -1938,7 +1919,7 @@ _address_arrow_pressed (GtkWidget *widget, GdkEventButton *button, EContactEdito
checked);
}
- result = _arrow_pressed (widget, button, editor, editor->address_popup, &editor->address_list, &editor->address_info, "label-address", "text-address", "Add new Address type");
+ result = _arrow_pressed (widget, button, editor, editor->address_popup, &editor->address_list, &editor->address_info, "label-address");
if (result != -1) {
set_address_field(editor, result);