"toggle_publ" => __("Toggle published"),
"toggle_unread" => __("Toggle unread"),
"edit_tags" => __("Edit tags"),
- "dismiss_selected" => __("Dismiss selected"),
- "dismiss_read" => __("Dismiss read"),
"open_in_new_window" => __("Open in new window"),
"catchup_below" => __("Mark below as read"),
"catchup_above" => __("Mark above as read"),
"*s" => "toggle_publ",
"u" => "toggle_unread",
"*t" => "edit_tags",
- "*d" => "dismiss_selected",
- "*x" => "dismiss_read",
"o" => "open_in_new_window",
"c p" => "catchup_below",
"c n" => "catchup_above",
editArticleTags(id);
};
}
- hotkey_actions["dismiss_selected"] = function() {
- dismissSelectedArticles();
- };
- hotkey_actions["dismiss_read"] = function() {
- dismissReadArticles();
- };
hotkey_actions["open_in_new_window"] = function() {
if (getActiveArticleId()) {
openArticleInNewWindow(getActiveArticleId());
if (isCdmMode()) {
if (!getInitParam("cdm_expanded")) {
cdmCollapseArticle(false, getActiveArticleId());
- } else {
- dismissArticle(getActiveArticleId());
}
} else {
closeArticlePanel();
}
}
-function dismissArticles(ids) {
- try {
-
- console.log("dismissArticles: " + ids);
-
- for (var i = 0; i < ids.length; i++) {
- var elem = $("RROW-" + ids[i]);
-
- new Effect.Fade(elem, {
- duration: 0.5, afterFinish: function (obj) {
- Element.remove(obj.element);
- }
- });
-
- if (ids[i] == getActiveArticleId()) {
- setActiveArticleId(0);
- }
- }
-
- selectionToggleUnread(false, false, false, ids);
-
- } catch (e) {
- exception_error("dismissArticles", e);
- }
-
-}
-
-function dismissArticle(id) {
- try {
- dismissArticles([id]);
- } catch (e) {
- exception_error("dismissArticle", e);
- }
-}
-
-function dismissSelectedArticles() {
- try {
- dismissArticles(getSelectedArticleIds2());
- } catch (e) {
- exception_error("dismissSelectedArticles", e);
- }
-}
-
-function dismissReadArticles() {
- try {
- var ids = getLoadedArticleIds();
- var tmp = [];
-
- ids.each(function(id) {
- var elem = $("RROW-" + id);
-
- if (elem && !elem.hasClassName("Unread")) {
- tmp.push(id);
- }
-
- });
-
- dismissArticles(tmp);
-
- } catch (e) {
- exception_error("dismissReadArticles", e);
- }
-}
-
function cdmClicked(event, id) {
try {
//var shift_key = event.shiftKey;