mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-10 17:35:00 -06:00
@@ -30,7 +30,7 @@
|
||||
}
|
||||
}).activate();
|
||||
|
||||
window.addEvent("domready", () => {
|
||||
window.addEventListener("DOMContentLoaded", () => {
|
||||
const hash = new URI().getData("hash");
|
||||
const oldPath = new URI().getData("path");
|
||||
const isFolder = ((new URI().getData("isFolder")) === "true");
|
||||
@@ -41,8 +41,10 @@
|
||||
if (!isFolder)
|
||||
$("rename").setSelectionRange(0, oldName.lastIndexOf("."));
|
||||
|
||||
$("renameButton").addEvent("click", (e) => {
|
||||
new Event(e).stop();
|
||||
$("renameButton").addEventListener("click", (e) => {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
|
||||
// check field
|
||||
const newName = $("rename").value.trim();
|
||||
if (newName === "") {
|
||||
|
||||
Reference in New Issue
Block a user