more fixes to folder dnd (folderview locking, feedback to the user, don't copy
filtering compiled regexps)
This commit is contained in:
parent
ae75ac2b18
commit
79c40228e8
5 changed files with 26 additions and 7 deletions
|
@ -1,3 +1,12 @@
|
|||
2002-11-08 [colin] 0.8.5claws100
|
||||
|
||||
* src/matcher.c
|
||||
Don't copy the compiled regexp (will be reevaluated)
|
||||
* src/folderview.c
|
||||
Lock folderview while moving
|
||||
* src/folder.c
|
||||
Provide info on what's happening to the user
|
||||
|
||||
2002-11-08 [colin] 0.8.5claws99
|
||||
|
||||
* src/folderview.c
|
||||
|
|
|
@ -11,7 +11,7 @@ MINOR_VERSION=8
|
|||
MICRO_VERSION=5
|
||||
INTERFACE_AGE=0
|
||||
BINARY_AGE=0
|
||||
EXTRA_VERSION=claws99
|
||||
EXTRA_VERSION=claws100
|
||||
VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
|
||||
|
||||
dnl set $target
|
||||
|
|
10
src/folder.c
10
src/folder.c
|
@ -50,6 +50,7 @@
|
|||
#include "scoring.h"
|
||||
#include "prefs_folder_item.h"
|
||||
#include "procheader.h"
|
||||
#include "statusbar.h"
|
||||
|
||||
static GList *folder_list = NULL;
|
||||
|
||||
|
@ -1444,7 +1445,7 @@ FolderItem *folder_item_move_recursive (FolderItem *src, FolderItem *dest)
|
|||
FolderItem *new_item;
|
||||
FolderItem *next_item;
|
||||
GNode *srcnode;
|
||||
|
||||
int cnt = 0;
|
||||
mlist = folder_item_get_msg_list(src);
|
||||
|
||||
/* move messages */
|
||||
|
@ -1455,14 +1456,21 @@ FolderItem *folder_item_move_recursive (FolderItem *src, FolderItem *dest)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
statusbar_print_all(_("Moving %s to %s..."), src->name, new_item->path);
|
||||
|
||||
if (new_item->folder == NULL)
|
||||
new_item->folder = dest->folder;
|
||||
|
||||
/* move messages */
|
||||
for (cur = mlist ; cur != NULL ; cur = cur->next) {
|
||||
MsgInfo * msginfo;
|
||||
cnt++;
|
||||
msginfo = (MsgInfo *) cur->data;
|
||||
folder_item_move_msg(new_item, msginfo);
|
||||
if (cnt%500)
|
||||
statusbar_print_all(_("Moving %s to %s (%d%%)..."), src->name,
|
||||
new_item->path,
|
||||
100*cnt/g_slist_length(mlist));
|
||||
}
|
||||
|
||||
/*copy prefs*/
|
||||
|
|
|
@ -2694,6 +2694,8 @@ static void folderview_drag_received_cb(GtkWidget *widget,
|
|||
STATUSBAR_PUSH(folderview->mainwin, buf);
|
||||
g_free(buf);
|
||||
main_window_cursor_wait(folderview->mainwin);
|
||||
gtk_widget_set_sensitive(folderview->ctree, FALSE);
|
||||
inc_lock();
|
||||
if ((new_item = folder_item_move_to(src_item, item)) != NULL) {
|
||||
gtk_drag_finish(drag_context, TRUE, TRUE, time);
|
||||
|
||||
|
@ -2718,7 +2720,9 @@ static void folderview_drag_received_cb(GtkWidget *widget,
|
|||
gtk_drag_finish(drag_context, FALSE, FALSE, time);
|
||||
STATUSBAR_PUSH(folderview->mainwin, _("Done."));
|
||||
main_window_cursor_normal(folderview->mainwin);
|
||||
}
|
||||
}
|
||||
inc_unlock();
|
||||
gtk_widget_set_sensitive(folderview->ctree, TRUE);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -259,10 +259,8 @@ MatcherProp *matcherprop_copy(MatcherProp *src)
|
|||
else
|
||||
prop->expr = NULL;
|
||||
prop->matchtype = src->matchtype;
|
||||
if (src->preg != NULL)
|
||||
memcpy(prop->preg, src->preg, sizeof(regex_t));
|
||||
else
|
||||
prop->preg = NULL;
|
||||
|
||||
prop->preg = NULL; /* will be re-evaluated */
|
||||
prop->value = src->value;
|
||||
prop->error = src->error;
|
||||
return prop;
|
||||
|
|
Loading…
Reference in a new issue