6 <title>QBT_TR(Please choose a new name for this RSS feed)QBT_TR[CONTEXT=RSSWidget]
</title>
7 <link rel=
"stylesheet" href=
"css/style.css?v=${CACHEID}" type=
"text/css">
8 <script src=
"scripts/lib/MooTools-Core-1.6.0-compat-compressed.js"></script>
9 <script src=
"scripts/lib/MooTools-More-1.6.0-compat-compressed.js"></script>
10 <script src=
"scripts/misc.js?locale=${LANG}&v=${CACHEID}"></script>
15 defaultEventType
: "keydown",
18 $("renameButton").click();
19 event
.preventDefault();
21 "Escape": (event
) => {
22 window
.parent
.qBittorrent
.Client
.closeWindows();
23 event
.preventDefault();
26 window
.parent
.qBittorrent
.Client
.closeWindows();
27 event
.preventDefault();
31 window
.addEventListener("DOMContentLoaded", () => {
32 const oldPath
= new URI().getData("oldPath");
34 $("rename").value
= oldPath
;
36 $("rename").setSelectionRange(0, oldPath
.length
);
38 $("renameButton").addEventListener("click", (e
) => {
43 const newPath
= $("rename").value
.trim();
45 alert("QBT_TR(Name cannot be empty)QBT_TR[CONTEXT=HttpServer]");
49 if (newPath
=== oldPath
) {
50 alert("QBT_TR(Name is unchanged)QBT_TR[CONTEXT=HttpServer]");
54 $("renameButton").disabled
= true;
57 url
: "api/v2/rss/moveItem",
63 onSuccess
: (response
) => {
64 window
.parent
.qBittorrent
.Rss
.updateRssFeedList();
65 window
.parent
.qBittorrent
.Client
.closeWindows();
67 onFailure
: (response
) => {
68 if (response
.status
=== 409)
69 alert(response
.responseText
);
70 $("renameButton").disabled
= false;
79 <div style=
"padding: 10px 10px 0px 10px;">
80 <label for=
"rename" style=
"font-weight: bold;">QBT_TR(New feed name:)QBT_TR[CONTEXT=RSSWidget]
</label>
81 <input type=
"text" id=
"rename" style=
"width: 320px;">
82 <div style=
"text-align: center; padding-top: 10px;">
83 <input type=
"button" value=
"QBT_TR(Save)QBT_TR[CONTEXT=HttpServer]" id=
"renameButton">