[Commits] [SCM] claws branch, master, updated. 4.3.1-53-gfc491788a
wwp at claws-mail.org
wwp at claws-mail.org
Sat Mar 22 16:35:01 UTC 2025
The branch, master has been updated
discards b80b5e3301ffb17042aea61a0757b981357355f1 (commit)
via fc491788a8d348d810ee2dcbdaadf5cdc3962b5f (commit)
This update added new revisions after undoing existing revisions. That is
to say, the old revision is not a strict subset of the new revision. This
situation occurs when you --force push a change and generate a repository
containing something like this:
* -- * -- B -- O -- O -- O (b80b5e3301ffb17042aea61a0757b981357355f1)
\
N -- N -- N (fc491788a8d348d810ee2dcbdaadf5cdc3962b5f)
When this happens we assume that you've already had alert emails for all
of the O revisions, and so we here report only the revisions in the N
branch from the common base, B.
Summary of changes:
- Log -----------------------------------------------------------------
commit fc491788a8d348d810ee2dcbdaadf5cdc3962b5f
Author: wwp <subscript at free.fr>
Date: Sat Mar 22 17:28:14 2025 +0100
RSSyl plugin: prefer "Refresh all" (feeds) to "Refresh recursively", the former used everywhere else.
RSSyl plugin: make 'Refresh all skips feeds programmed to be refreshed manually' setting to apply in case of automated refreshing only (i.e. not manually).
diff --git a/src/plugins/rssyl/rssyl.c b/src/plugins/rssyl/rssyl.c
index b85a8f6d9..ad6f88dce 100644
--- a/src/plugins/rssyl/rssyl.c
+++ b/src/plugins/rssyl/rssyl.c
@@ -124,13 +124,15 @@ static void rssyl_create_default_mailbox(void)
static gboolean rssyl_update_all_feeds_deferred(gpointer data)
{
- rssyl_update_all_feeds();
+ /* automated refreshing */
+ rssyl_update_all_feeds(FALSE);
return FALSE;
}
static void rssyl_toolbar_cb_refresh_all_feeds(gpointer parent, const gchar *item_name, gpointer data)
{
- rssyl_update_all_feeds();
+ /* refreshing upon user manual request */
+ rssyl_update_all_feeds(TRUE);
}
void rssyl_init(void)
diff --git a/src/plugins/rssyl/rssyl_cb_menu.c b/src/plugins/rssyl/rssyl_cb_menu.c
index eee3a134b..3b879bfde 100644
--- a/src/plugins/rssyl/rssyl_cb_menu.c
+++ b/src/plugins/rssyl/rssyl_cb_menu.c
@@ -332,7 +332,7 @@ void rssyl_update_all_cb( GtkAction *action, gpointer data)
return;
}
- rssyl_update_recursively(item);
+ rssyl_update_recursively(item, TRUE);
}
void rssyl_remove_mailbox_cb(GtkAction *action, gpointer data)
diff --git a/src/plugins/rssyl/rssyl_gtk.c b/src/plugins/rssyl/rssyl_gtk.c
index a9ffa6725..61b123404 100644
--- a/src/plugins/rssyl/rssyl_gtk.c
+++ b/src/plugins/rssyl/rssyl_gtk.c
@@ -44,7 +44,7 @@ static char *rssyl_popup_menu_labels[] =
N_("_Refresh feed"),
N_("Feed pr_operties"),
N_("Rena_me..."),
- N_("R_efresh recursively"),
+ N_("R_efresh all feeds"),
N_("Subscribe _new feed..."),
N_("Create new _folder..."),
N_("Import feed list..."),
diff --git a/src/plugins/rssyl/rssyl_update_feed.c b/src/plugins/rssyl/rssyl_update_feed.c
index eca2c970a..84eeb2bf6 100644
--- a/src/plugins/rssyl/rssyl_update_feed.c
+++ b/src/plugins/rssyl/rssyl_update_feed.c
@@ -313,7 +313,7 @@ gboolean rssyl_update_feed(RFolderItem *ritem, RSSylVerboseFlags verbose)
rssyl_deleted_update(ritem);
debug_print("RSSyl: STARTING TO PARSE FEED\n");
- if( ctx->success && !(ctx->success = rssyl_parse_feed(ritem, ctx->feed)) ) {
+ if( ctx->success && !(ctx->success = rssyl_parse_feed(ritem, ctx->feed)) ) {
/* both libcurl and libfeed were happy, but we weren't */
debug_print("RSSyl: Error processing feed\n");
if( verbose & RSSYL_SHOW_ERRORS ) {
@@ -357,7 +357,7 @@ gboolean rssyl_update_feed(RFolderItem *ritem, RSSylVerboseFlags verbose)
return success;
}
-static gboolean rssyl_update_recursively_func(GNode *node, gpointer data)
+static gboolean rssyl_update_recursively_func(GNode *node, gpointer data, gboolean manual_refresh)
{
FolderItem *item;
RFolderItem *ritem;
@@ -368,8 +368,10 @@ static gboolean rssyl_update_recursively_func(GNode *node, gpointer data)
ritem = (RFolderItem *)item;
if( ritem->url != NULL ) {
- if(rssyl_prefs_get()->refresh_all_skips &&
- (ritem->default_refresh_interval == FALSE) && (ritem->refresh_interval == 0)) {
+ if((manual_refresh == FALSE) &&
+ rssyl_prefs_get()->refresh_all_skips &&
+ (ritem->default_refresh_interval == FALSE) &&
+ (ritem->refresh_interval == 0)) {
debug_print("RSSyl: Skipping feed '%s'\n", item->name);
} else {
debug_print("RSSyl: Updating feed '%s'\n", item->name);
@@ -381,31 +383,49 @@ static gboolean rssyl_update_recursively_func(GNode *node, gpointer data)
return FALSE;
}
-void rssyl_update_recursively(FolderItem *item)
+static gboolean rssyl_update_recursively_automated_func(GNode *node, gpointer data)
+{
+ return rssyl_update_recursively_func(node, data, FALSE);
+}
+
+static gboolean rssyl_update_recursively_manually_func(GNode *node, gpointer data)
+{
+ return rssyl_update_recursively_func(node, data, TRUE);
+}
+
+void rssyl_update_recursively(FolderItem *item, gboolean manual_refresh)
{
g_return_if_fail(item != NULL);
g_return_if_fail(item->folder != NULL);
-
- if( item->folder->klass != rssyl_folder_get_class() )
- return;
+ g_return_if_fail(item->folder->klass == rssyl_folder_get_class());
debug_print("Recursively updating '%s'\n", item->name);
g_node_traverse(item->node, G_PRE_ORDER, G_TRAVERSE_ALL, -1,
- rssyl_update_recursively_func, NULL);
+ manual_refresh ? rssyl_update_recursively_manually_func : rssyl_update_recursively_automated_func,
+ NULL);
}
-void rssyl_update_all_func(FolderItem *item, gpointer data)
+static void rssyl_update_all_func(FolderItem *item, gpointer data, gboolean manual_refresh)
{
/* Only try to refresh our feed folders */
- if( !IS_RSSYL_FOLDER_ITEM(item) )
- return;
+ g_return_if_fail(IS_RSSYL_FOLDER_ITEM(item));
+ g_return_if_fail(folder_item_parent(item) == NULL);
- if( folder_item_parent(item) == NULL )
- rssyl_update_recursively(item);
+ rssyl_update_recursively(item, manual_refresh);
+}
+
+static void rssyl_update_all_automated_func(FolderItem *item, gpointer data)
+{
+ rssyl_update_all_func(item, data, FALSE);
+}
+
+static void rssyl_update_all_manually_func(FolderItem *item, gpointer data)
+{
+ rssyl_update_all_func(item, data, TRUE);
}
-void rssyl_update_all_feeds(void)
+void rssyl_update_all_feeds(gboolean manual_refresh)
{
if (prefs_common_get_prefs()->work_offline &&
!inc_offline_should_override(TRUE,
@@ -413,5 +433,7 @@ void rssyl_update_all_feeds(void)
return;
}
- folder_func_to_all_folders((FolderItemFunc)rssyl_update_all_func, NULL);
+ folder_func_to_all_folders(
+ (FolderItemFunc)(manual_refresh? rssyl_update_all_manually_func : rssyl_update_all_automated_func),
+ NULL);
}
diff --git a/src/plugins/rssyl/rssyl_update_feed.h b/src/plugins/rssyl/rssyl_update_feed.h
index 3a353bba5..ba8b683cd 100644
--- a/src/plugins/rssyl/rssyl_update_feed.h
+++ b/src/plugins/rssyl/rssyl_update_feed.h
@@ -30,8 +30,8 @@ RFetchCtx *rssyl_prep_fetchctx_from_item(RFolderItem *ritem);
gboolean rssyl_update_feed(RFolderItem *ritem, RSSylVerboseFlags verbose);
-void rssyl_update_recursively(FolderItem *item);
+void rssyl_update_recursively(FolderItem *item, gboolean manual_refresh);
-void rssyl_update_all_feeds(void);
+void rssyl_update_all_feeds(gboolean manual_refresh);
#endif /* __RSSYL_UPDATE_FEED */
-----------------------------------------------------------------------
hooks/post-receive
--
Claws Mail
More information about the Commits
mailing list