aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--filter/ChangeLog13
-rw-r--r--filter/rule-editor.c30
-rw-r--r--filter/vfolder-rule.c29
3 files changed, 44 insertions, 28 deletions
diff --git a/filter/ChangeLog b/filter/ChangeLog
index af282e11e3..6c311910bb 100644
--- a/filter/ChangeLog
+++ b/filter/ChangeLog
@@ -1,3 +1,8 @@
+2001-06-29 Jeffrey Stedfast <fejj@ximian.com>
+
+ * rule-editor.c (rule_editor_construct): Set the filter-rule
+ dialog to be user-resizable.
+
2001-06-27 Jeffrey Stedfast <fejj@ximian.com>
* filtertypes.xml: Make "Move" the default action.
@@ -8,10 +13,10 @@
2001-05-08 Gediminas Paulauskas <menesis@delfi.lt>
- * filter-rule.c (xml_decode): allow "_title" in user rules. translate
- them and encode to utf8.
- (get_rule_part_widget): do not call gettext on part->title. It is always
- translated already.
+ * filter-rule.c (xml_decode): allow "_title" in user
+ rules. translate them and encode to utf8.
+ (get_rule_part_widget): do not call gettext on part->title. It is
+ always translated already.
2001-04-26 Jeffrey Stedfast <fejj@ximian.com>
diff --git a/filter/rule-editor.c b/filter/rule-editor.c
index 50af58e414..33e85aea73 100644
--- a/filter/rule-editor.c
+++ b/filter/rule-editor.c
@@ -460,22 +460,24 @@ rule_editor_construct(RuleEditor *re, RuleContext *context, GladeXML *gui, const
int i;
re->context = context;
- gtk_object_ref((GtkObject *)context);
-
- w = glade_xml_get_widget(gui, "rule_editor");
- gtk_box_pack_start((GtkBox *)GNOME_DIALOG(re)->vbox, w, TRUE, TRUE, 0);
+ gtk_object_ref (GTK_OBJECT (context));
+
+ gtk_window_set_policy (GTK_WINDOW (re), FALSE, TRUE, FALSE);
+
+ w = glade_xml_get_widget (gui, "rule_editor");
+ gtk_box_pack_start (GTK_BOX (GNOME_DIALOG (re)->vbox), w, TRUE, TRUE, 0);
- for (i=0; i<BUTTON_LAST; i++) {
- re->priv->buttons[i] = (GtkButton *)w = glade_xml_get_widget(gui, edit_buttons[i].name);
- gtk_signal_connect(GTK_OBJECT(w), "clicked", edit_buttons[i].func, re);
+ for (i = 0; i < BUTTON_LAST; i++) {
+ re->priv->buttons[i] = (GtkButton *)w = glade_xml_get_widget (gui, edit_buttons[i].name);
+ gtk_signal_connect (GTK_OBJECT (w), "clicked", edit_buttons[i].func, re);
}
-
+
re->list = (GtkList *) w = glade_xml_get_widget(gui, "rule_list");
- gtk_signal_connect(GTK_OBJECT(w), "select_child", select_rule, re);
- gtk_signal_connect(GTK_OBJECT(w), "button_press_event", double_click, re);
-
- rule_editor_set_source(re, source);
-
- gnome_dialog_append_buttons ((GnomeDialog *)re, GNOME_STOCK_BUTTON_OK,
+ gtk_signal_connect (GTK_OBJECT (w), "select_child", select_rule, re);
+ gtk_signal_connect (GTK_OBJECT (w), "button_press_event", double_click, re);
+
+ rule_editor_set_source (re, source);
+
+ gnome_dialog_append_buttons (GNOME_DIALOG (re), GNOME_STOCK_BUTTON_OK,
GNOME_STOCK_BUTTON_CANCEL, NULL);
}
diff --git a/filter/vfolder-rule.c b/filter/vfolder-rule.c
index c9abcf5f4e..bf1bdc479e 100644
--- a/filter/vfolder-rule.c
+++ b/filter/vfolder-rule.c
@@ -115,20 +115,22 @@ vfolder_rule_finalise(GtkObject *obj)
* Return value: A new #VfolderRule object.
**/
VfolderRule *
-vfolder_rule_new(void)
+vfolder_rule_new (void)
{
VfolderRule *o = (VfolderRule *)gtk_type_new(vfolder_rule_get_type ());
return o;
}
-void vfolder_rule_add_source (VfolderRule *vr, const char *uri)
+void
+vfolder_rule_add_source (VfolderRule *vr, const char *uri)
{
g_assert(IS_VFOLDER_RULE(vr));
vr->sources = g_list_append(vr->sources, g_strdup(uri));
}
-const char *vfolder_rule_find_source (VfolderRule *vr, const char *uri)
+const char *
+vfolder_rule_find_source (VfolderRule *vr, const char *uri)
{
GList *l;
@@ -145,7 +147,8 @@ const char *vfolder_rule_find_source (VfolderRule *vr, const char *uri)
return NULL;
}
-void vfolder_rule_remove_source (VfolderRule *vr, const char *uri)
+void
+vfolder_rule_remove_source (VfolderRule *vr, const char *uri)
{
char *found;
@@ -158,7 +161,8 @@ void vfolder_rule_remove_source (VfolderRule *vr, const char *uri)
}
}
-const char *vfolder_rule_next_source (VfolderRule *vr, const char *last)
+const char *
+vfolder_rule_next_source (VfolderRule *vr, const char *last)
{
GList *node;
@@ -176,7 +180,8 @@ const char *vfolder_rule_next_source (VfolderRule *vr, const char *last)
return NULL;
}
-static xmlNodePtr xml_encode(FilterRule *fr)
+static xmlNodePtr
+xml_encode (FilterRule *fr)
{
xmlNodePtr node, set, work;
GList *l;
@@ -196,7 +201,8 @@ static xmlNodePtr xml_encode(FilterRule *fr)
return node;
}
-static int xml_decode(FilterRule *fr, xmlNodePtr node, struct _RuleContext *f)
+static int
+xml_decode (FilterRule *fr, xmlNodePtr node, struct _RuleContext *f)
{
xmlNodePtr set, work;
int result;
@@ -272,7 +278,8 @@ select_source_with(GtkWidget *w, struct _source_data *data)
filter_rule_set_source((FilterRule *)data->vr, source);
}
-static void source_add(GtkWidget *widget, struct _source_data *data)
+static void
+source_add(GtkWidget *widget, struct _source_data *data)
{
const char *allowed_types[] = { "mail", NULL };
char *def, *uri;
@@ -304,7 +311,8 @@ static void source_add(GtkWidget *widget, struct _source_data *data)
set_sensitive(data);
}
-static void source_remove(GtkWidget *widget, struct _source_data *data)
+static void
+source_remove(GtkWidget *widget, struct _source_data *data)
{
const char *source;
int index = 0;
@@ -335,7 +343,8 @@ const char *source_names[] = {
"local_remote_active"
};
-static GtkWidget *get_widget(FilterRule *fr, struct _RuleContext *f)
+static GtkWidget *
+get_widget(FilterRule *fr, struct _RuleContext *f)
{
GtkWidget *widget, *frame, *w;
GladeXML *gui;