From: Melvin Hadasht Date: Tue, 9 Apr 2002 21:54:31 +0000 (+0000) Subject: Made 'Ctrl-Enter' on send ignore some modifiers X-Git-Tag: rel_0_7_5~45 X-Git-Url: http://git.claws-mail.org/?p=claws.git;a=commitdiff_plain;h=9bed35ae47742ed1fc32132ed554426545d6a014 Made 'Ctrl-Enter' on send ignore some modifiers --- diff --git a/ChangeLog.claws b/ChangeLog.claws index 0111a97fc..4e46d91e0 100644 --- a/ChangeLog.claws +++ b/ChangeLog.claws @@ -1,3 +1,10 @@ +2002-04-09 [melvin] 0.7.4claws75 + + * src/compose.c + Made 'Ctrl-Enter' on send ignore some modifiers + (LOCK_MASK, MOD2, MOD3, MOD4, MOD5). Make it possible + to bind other *-Enter (but not Alt-Enter). + 2002-04-09 [paul] 0.7.4claws74 * sync with 0.7.4cvs35 diff --git a/configure.in b/configure.in index 9c46acac8..44cd47262 100644 --- a/configure.in +++ b/configure.in @@ -8,7 +8,7 @@ MINOR_VERSION=7 MICRO_VERSION=4 INTERFACE_AGE=0 BINARY_AGE=0 -EXTRA_VERSION=claws74 +EXTRA_VERSION=claws75 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION dnl set $target diff --git a/src/compose.c b/src/compose.c index 8a28aaabc..f426b005b 100644 --- a/src/compose.c +++ b/src/compose.c @@ -6639,20 +6639,21 @@ static gboolean compose_send_control_enter(Compose *compose) GtkAccelEntry *accel; GtkWidget *send_menu; GSList *list; + gint ignored_mods = (GDK_LOCK_MASK | GDK_MOD2_MASK | GDK_MOD3_MASK + | GDK_MOD4_MASK | GDK_MOD5_MASK); ev = gtk_get_current_event(); if (ev->type != GDK_KEY_PRESS) return FALSE; kev = (GdkEventKey *)ev; - if (!(kev->keyval == GDK_Return && (kev->state & GDK_CONTROL_MASK))) - return FALSE; ifactory = gtk_item_factory_from_widget(compose->menubar); send_menu = gtk_item_factory_get_widget(ifactory, "/Message/Send"); list = gtk_accel_group_entries_from_object(GTK_OBJECT(send_menu)); accel = (GtkAccelEntry *)list->data; if (accel->accelerator_key == kev->keyval && - accel->accelerator_mods == kev->state) { + (accel->accelerator_mods & ~ignored_mods) == + (kev->state & ~ignored_mods)) { compose_send_cb(compose, 0, NULL); return TRUE; }