X-Git-Url: http://mop.ddnsfree.com/gitweb/?a=blobdiff_plain;f=web%2Fcommons.js;h=7ba8b31d3f85fd72a910acc17f9da2ff0bd84023;hb=9c32b198f916bdf20fc051b86bba6092b105ca9e;hp=713a4bea8cc377b13298bf941b0e89d032bc3e8b;hpb=e05b72f2d772b765dd9bd54098cd2c4efbb7b06b;p=brisk.git diff --git a/web/commons.js b/web/commons.js index 713a4be..7ba8b31 100644 --- a/web/commons.js +++ b/web/commons.js @@ -54,6 +54,8 @@ var mlang_commons = { 'imgload_a' : { 'it' : 'Immagine caricate ', function $(id) { return document.getElementById(id); } +function $$(win, id) { return win.document.getElementById(id); } + function dec2hex(d, padding) { var hex = Number(d).toString(16); @@ -451,6 +453,27 @@ function act_logout(exitlock) send_mesg("logout|"+exitlock); } +var moder_win = null; +var moder_cur = -1; +function act_moderate() +{ + send_mesg("moderate"); +} + +function moderate(enable) +{ + if (enable) { + moder_win = window.open("moderation.php", "moderation", "width=800,height=600,toolbar=no,location=no,menubar=no,status=no"); + } + else { + if (moder_win != null) { + moder_win.close(); + moder_win = null; + moder_cur = -1; + } + } +} + function act_reloadroom() { window.onunload = null; @@ -458,6 +481,7 @@ function act_reloadroom() document.location.assign("index.php"); } + function act_shutdown() { var c = 0;