, function(res=null) {
- if (!res) return;
- var value = (res.text || "").trim();
- var values = value.split(/[\s,;\n]+/g);
- if (values.length == 0) return;
- for (var v in values) {
- var found;
- for (var i = 0; i < ab.peers.length; ++i) {
- if (ab.peers[i].id == v) {
- found = true;
- break;
+
,
+ "",
+ function(res=null) {
+ if (!res) return;
+ var value = (res.text || "").trim();
+ var values = value.split(/[\s,;\n]+/g);
+ if (values.length == 0) return;
+ for (var v in values) {
+ var found;
+ for (var i = 0; i < ab.peers.length; ++i) {
+ if (ab.peers[i].id == v) {
+ found = true;
+ break;
+ }
}
+ if (found) continue;
+ ab.peers.push({ id: v });
}
- if (found) continue;
- ab.peers.push({ id: v });
- }
- updateAb();
- me.update();
- }, 300);
+ updateAb();
+ me.update();
+ },
+ 300);
}
event click $(#add-tag) (_, __) {
@@ -105,7 +111,7 @@ class AddressBook: Reactor.Component
msgbox("custom-add-tag", translate("Add Tag"),
{translate("whitelist_sep")}
-
, function(res=null) {
+ , "", function(res=null) {
if (!res) return;
var value = (res.text || "").trim();
var values = value.split(/[\s,;\n]+/g);
@@ -483,7 +489,7 @@ class SessionList: Reactor.Component {
msgbox("custom-rename", "Rename", "
\
\
\
- ", function(res=null) {
+ ", "", function(res=null) {
if (!res) return;
var name = (res.name || "").trim();
if (name != old_name) {
@@ -506,7 +512,7 @@ class SessionList: Reactor.Component {
}
}
if (!peer) return;
- msgbox("custom-edit-tag", "Edit Tag", , function(res=null) {
+ msgbox("custom-edit-tag", "Edit Tag", , "", function(res=null) {
if (!res) return;
peer.tags = selectTags.tags;
updateAb();
@@ -738,7 +744,7 @@ function editRdpPort() {
{translate('Port')}:{port}
{translate('Username')}:
{translate('Password')}:
- , function(res=null) {
+ , "", function(res=null) {
if (!res) return;
var p = (res.port || '').trim();
if (p != p0) {
diff --git a/src/ui/common.tis b/src/ui/common.tis
index e591f45a3..76e0fb84e 100644
--- a/src/ui/common.tis
+++ b/src/ui/common.tis
@@ -232,7 +232,7 @@ class ChatBox: Reactor.Component {
/******************** start of msgbox ****************************************/
var remember_password = false;
-function msgbox(type, title, content, link, callback=null, height=180, width=500, hasRetry=false, contentStyle="") {
+function msgbox(type, title, content, link="", callback=null, height=180, width=500, hasRetry=false, contentStyle="") {
$(body).scrollTo(0, 0);
if (!type) {
closeMsgbox();
diff --git a/src/ui/file_transfer.tis b/src/ui/file_transfer.tis
index 38c6321dc..451117403 100644
--- a/src/ui/file_transfer.tis
+++ b/src/ui/file_transfer.tis
@@ -535,7 +535,7 @@ class FolderView : Reactor.Component {
msgbox("custom", translate("Create Folder"), "
\
" + translate("Please enter the folder name") + ":
\
\
-
", function(res=null) {
+ ", "", function(res=null) {
if (!res) return;
if (!res.name) return;
var name = res.name.trim();
@@ -716,7 +716,7 @@ function confirmDelete(id ,path, is_remote) {
msgbox("custom-skip", "Confirm Delete", "
\
" + translate('Are you sure you want to delete this file?') + "