Secure4_Med_Toggle{
menuchecked=(getpref(BOOL,"dom.disable_window_move_resize")==true);
getpref(BOOL,"dom.disable_window_move_resize")==true?&_Secure4_Med_Disable:&_Secure4_Med_Enable;
}

_Secure4_Med_Enable{
statusbar(sub("%s",$on,_("Secure4-Med %s")));
setpref(BOOL,"browser.cache.offline.enable",false);
setpref(BOOL,"svg.enabled",false);
setpref(BOOL,"editor.use_css",false);
setpref(BOOL,"dom.disable_window_move_resize",true);
setpref(BOOL,"dom.allow_scripts_to_close_windows",false);
setpref(BOOL,"dom.disable_window_flip",true);
setpref(BOOL,"dom.disable_window_status_change",true);
setpref(BOOL,"browser.blink_allowed",false);
setpref(BOOL,"dom.event.contextmenu.enabled",false);
setpref(BOOL,"gfx.downloadable_fonts.enabled",false);
setpref(BOOL,"dom.indexedDB.enabled",false);
setpref(INT,"dom.storage.default_quota",1000);
setpref(BOOL,"media.webm.enabled",false);
setpref(INT,"network.websocket.max-message-size",2000000);
setpref(INT,"offline-apps.quota.max",2000);
setpref(BOOL,"intl.locale.matchOS",false);
}

_Secure4_Med_Disable{
statusbar(sub("%s",$off,_("Page load Secure-Med %s")));
delpref("browser.cache.offline.enable");
delpref("svg.enabled");
delpref("editor.use_css");
delpref("dom.disable_window_move_resize");
delpref("dom.allow_scripts_to_close_windows");
delpref("dom.disable_window_flip");
delpref("dom.disable_window_status_change");
delpref("browser.blink_allowed");
delpref("dom.event.contextmenu.enabled");
delpref("gfx.downloadable_fonts.enabled");
delpref("dom.indexedDB.enabled");
delpref("dom.storage.default_quota");
delpref("media.webm.enabled");
delpref("network.websocket.max-message-size");
delpref("offline-apps.quota.max");
delpref("intl.locale.matchOS");
}

_Secure4_Med_BuildMenu{
# tools menu
setmenu(Settings,macro,"Secure-Med",Secure4_Med_Toggle);
}
$OnInit=$OnInit."_Secure4_Med_BuildMenu;";

$macroModules=$macroModules."Secure4_Med;";