summaryrefslogtreecommitdiff
path: root/js/prefs.js
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2018-12-02 11:34:57 +0300
committerAndrew Dolgov <[email protected]>2018-12-02 11:34:57 +0300
commit2e985d173352487f96984577ac512a3639267edf (patch)
treec2ca993754b0c8cee1fc5491920871f3773ea8c8 /js/prefs.js
parente23b6e397dbbbba90f9a15a6fe2d45eb862efdc5 (diff)
move some label helper functions to prefLabelTree
Diffstat (limited to 'js/prefs.js')
-rwxr-xr-xjs/prefs.js54
1 files changed, 0 insertions, 54 deletions
diff --git a/js/prefs.js b/js/prefs.js
index c2ff01d47..05023b053 100755
--- a/js/prefs.js
+++ b/js/prefs.js
@@ -316,19 +316,6 @@ function editFilter(id) {
dialog.show();
}
-
-function getSelectedLabels() {
- const tree = dijit.byId("labelTree");
- const items = tree.model.getCheckedItems();
- const rv = [];
-
- items.each(function(item) {
- rv.push(tree.model.store.getValue(item, 'bare_id'));
- });
-
- return rv;
-}
-
function getSelectedUsers() {
return Tables.getSelected("prefUserList");
}
@@ -372,28 +359,6 @@ function getSelectedFilters() {
}
-function removeSelectedLabels() {
-
- const sel_rows = getSelectedLabels();
-
- if (sel_rows.length > 0) {
- if (confirm(__("Remove selected labels?"))) {
- notify_progress("Removing selected labels...");
-
- const query = { op: "pref-labels", method: "remove",
- ids: sel_rows.toString() };
-
- xhrPost("backend.php", query, () => {
- updateLabelList();
- });
- }
- } else {
- alert(__("No labels are selected."));
- }
-
- return false;
-}
-
function removeSelectedUsers() {
const sel_rows = getSelectedUsers();
@@ -906,25 +871,6 @@ function opmlRegenKey() {
return false;
}
-function labelColorReset() {
- const labels = getSelectedLabels();
-
- if (labels.length > 0) {
- if (confirm(__("Reset selected labels to default colors?"))) {
-
- const query = { op: "pref-labels", method: "colorreset",
- ids: labels.toString() };
-
- xhrPost("backend.php", query, () => {
- updateLabelList();
- });
- }
-
- } else {
- alert(__("No labels are selected."));
- }
-}
-
function editProfiles() {
if (dijit.byId("profileEditDlg"))