From 64a2875dcc6cb847ffdd43196bf27b5019e12419 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Wed, 24 May 2006 04:15:04 +0100 Subject: [PATCH] quick unsubscribe prompt shows feed name --- functions.js | 10 +++++++++- tt-rss.js | 4 +++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/functions.js b/functions.js index e58a9703..f7e29888 100644 --- a/functions.js +++ b/functions.js @@ -1181,4 +1181,12 @@ function fatalError(code, message) { } } - +function getFeedName(id) { + var d = getFeedsContext().document; + var e = d.getElementById("FEEDN-" + id); + if (e) { + return e.innerHTML.stripTags(); + } else { + return null; + } +} diff --git a/tt-rss.js b/tt-rss.js index 0b00737a..9e6d70c7 100644 --- a/tt-rss.js +++ b/tt-rss.js @@ -436,8 +436,10 @@ function quickMenuGo(opid) { alert("Please select some feed first."); return; } + + var fn = getFeedName(actid); - if (confirm("Unsubscribe from current feed?")) { + if (confirm("Unsubscribe from " + fn + "?")) { qfdDelete(actid); } -- 2.39.2