home *** CD-ROM | disk | FTP | other *** search
-
- function CheckSecuritySlider() {
- var securitySlider = document.getElementById('securitySlider');
- var secBtnMarker = document.getElementById('securitycenter-marker');
- if(securitySlider) {
- if(securitySlider.status == "sliding") {
- setTimeout("CheckSecuritySlider()", 30);
- }
- else {
- reshuffleToolbars(true);
- // BC: 9/28/2005: Changed the arrow to show open/close, more css control.
- if (secBtnMarker.getAttribute('class') == 'open') {
- secBtnMarker.setAttribute('class', 'close');
- } else {
- secBtnMarker.setAttribute('class', 'open');
- }
- }
- }
- }
-
- function ToggleSecuritySuite(movingDirection) {
- var securitySlider = document.getElementById('securitySlider');
- if(securitySlider) {
- if(!movingDirection) {
- movingDirection = securitySlider.position == "center"? "left" : "center";
- }
- else if(movingDirection == securitySlider.position) {
- return;
- }
-
- if(movingDirection == "center") {
- securitySlider.start(null, movingDirection, 30, 1.5, 1, 100);
- }
- else {
- securitySlider.start(null, movingDirection, 30, 1, 20, 20);
- }
- CheckSecuritySlider();
- }
- }
-
- function OpenSecurityCenter() {
- // MERC (rpaul) quick function to open security center tab of site control preferences
- var prefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);
- if (prefs)
- prefs.setCharPref("browser.sitecontrols.prefs", "prefsTab");
-
- openPrefs(PREF_SITECONTROLS);
- }
-
- var currentSecurityButtonPopup = null;
- function CloseCurrentSecurityButtonPopup() {
- try {
- if(currentSecurityButtonPopup) {
- document.getElementById(currentSecurityButtonPopup).hidePopup();
- currentSecurityButtonPopup = null;
- }
- }
- catch(ex) {
- }
- }
-
- function OpenSecurityButtonPopup(popupId) {
- // if(currentSecurityButtonPopup) {
- // CloseCurrentSecurityButtonPopup();
- // }
-
- //balloonhelp.CancelBalloonHelpShow();
- var chMenu = document.getElementById(popupId);
- chMenu.showPopup(document.getElementById('securitySlider'),-1,-1,'popup','bottomright','topright');
- //currentSecurityButtonPopup = popupId;
- }
-
- function SecurityButtonBalloon(popupId, aButton, balloonTitle, balloonDesc) {
- if(currentSecurityButtonPopup) {
- // either balloon help or the drop down can show up, but not both
- if(currentSecurityButtonPopup == popupId) {
- // current button has an popup open, do not show the balloon
- return;
- }
- else {
- CloseCurrentSecurityButtonPopup();
- }
- }
-
- // the slider has some internal shifting effect for popups, so we need to adjust the offset of the popup position
- balloonhelp.ShowBalloonHelpDelayed('',aButton,balloonTitle,balloonDesc, null, null, document.getElementById('securitySlider'), 0-240, 10);
- }
-
-