Prophesy Fulfillment

image_pdfimage_print

Apologetic Tables

Copyright 2011 Churches of Christ USA. All rights reserved.

Web Hosting by Yahoo!

Churches of Christ USA
Tulsa, OK 74135
ph: 918.949.6902
alt: 903.277.1536

// setstats

 

 

 

// <![CDATA[

YAHOO.namespace(‘Smb.Asteroids’);
var YSA = YAHOO.Smb.Asteroids;

YSA.Nav = {
isNavNorth : false,
tmr : null,
tmrInterval : 600,
prevCloseNode : null,
isFirstVisit : true,

openSub : function(navNode) {
$LOG(‘openSub’);

// Clear the timer if any, and if the previously opened subnav is still open (timeout expiration)
YSA.Nav.clearTimer();
YSA.Nav.closePrevSubMenu();

// For horizontal navigation, set the top position of sub-nav as the height of the ‘trigger’ element.
if (YSA.Nav.isNavNorth) {
var subNavNode = navNode.getElementsByTagName(‘ul’)[0];
subNavNode.style.top = navNode.offsetHeight + ‘px’;
}

$D.addClass(navNode, ‘opened’);
$D.addClass(‘admincontrols’, ‘displayNone’);
},
closeSub : function(navNode) {
$LOG(‘closeSub’);
YSA.Nav.clearTimer();
YSA.Nav.prevCloseNode = navNode;
YSA.Nav.tmr = setTimeout(function() { YSA.Nav.hideSub(navNode); }, YSA.Nav.tmrInterval);
},
hideSub : function(navNode) {
YSA.Nav.clearTimer();

// For key board accessibility, the active sub menu is display:block., not none. So giving -999 to move it off screen in hide mode
if (YSA.Nav.isNavNorth && $D.hasClass(navNode, ‘active’)) {
var subNavNode = navNode.getElementsByTagName(‘ul’)[0];
subNavNode.style.top = ‘-999px’;
}
$D.removeClass(navNode, ‘opened’);
$D.removeClass(‘admincontrols’, ‘displayNone’);
},
closePrevSubMenu : function() {
if (YSA.Nav.prevCloseNode) {
$LOG(‘Closing previous sub nav’);
YSA.Nav.hideSub(YSA.Nav.prevCloseNode);
YSA.Nav.prevCloseNode = null;
}
},
isSubOpen : function(navNode) {
return $D.hasClass(navNode, ‘opened’);
},
toggleSub : function(navNode) {
var NAV = YSA.Nav;
if (NAV.isSubOpen(navNode)) {
NAV.closeSub(navNode);
} else {
NAV.openSub(navNode);
}
},
mouseOverTrigger : function(e) {
$LOG(‘mouseOverTrigger’);
YSA.Nav.openSub(this);
},
mouseOutTrigger : function(e) {
$LOG(‘mouseOutTrigger’);
var target = $E.getTarget(e);
var relatedTarget = $E.getRelatedTarget(e);
$LOG(target);
$LOG(relatedTarget);
YSA.Nav.closeSub(this);
},
mouseOverMainNav : function(e) {
$LOG(‘mouseOverMainNav’);
if (!$D.hasClass(this, ‘trigger’)) {
YSA.Nav.closePrevSubMenu();
}
},
toggleClicked : function(e) {
$LOG(‘toggle clicked’);
$LOG(e);
$E.stopEvent(e);
YSA.Nav.toggleSub(this.parentNode);
},
clearTimer : function() {
$LOG(‘Clearing Nav Timer’);
if (YSA.Nav.tmr) {
clearTimeout(YSA.Nav.tmr);
}
YSA.Nav.tmr = null;
},
clearSubNavStyles : function() {
/* For horizontal navigation, we set the ‘top’ of subNav to align it with the bottom of trigger
Now if the user chage the template from ribbon, remove this inline style. Else this old inline value will take precedence! */
var subNavNode;
var navDiv = $(‘navigation’);
var triggers = $D.getElementsByClassName(‘trigger’, ”, navDiv);
for (var el in triggers) {
if (YAHOO.lang.hasOwnProperty(triggers, el)) {
subNavNode = triggers[el].getElementsByTagName(‘ul’)[0];
subNavNode.style.top = ”;
}
}
},
initNavSettings : function() {
var wrapperDiv = $(‘wrapper’);
YSA.Nav.isNavNorth = (wrapperDiv && $D.hasClass(wrapperDiv, ‘navpos_north’)) ? true : false;
},
init : function() {
// For the first visit, subscribe to the layout(template) change event
// When user changes template from the ribbon, we need to re-init this JS, based on the new templates settings.
if (YSA.Nav.isFirstVisit) {
YSA.Nav.isFirstVisit = false;
if (YSA.UiMgr) {
YSA.UiMgr.Layout.onChange.eventObj.subscribe(
function() { YSA.Nav.init() });
}
} else {
YSA.Nav.clearSubNavStyles();
}

YSA.Nav.initNavSettings();
var navDiv = $(‘navigation’);
if (! $D.hasClass(navDiv, ‘sub_dynamic’)) {
return;
}
YSA.Nav.initNavSettings();
var triggers = $D.getElementsByClassName(‘trigger’, ”, navDiv);
$E.on(triggers, ‘mouseover’, this.mouseOverTrigger);
$E.on(triggers, ‘mouseout’, this.mouseOutTrigger);
var toggles = $D.getElementsByClassName(‘toggle’, ‘a’, navDiv);
$E.on(toggles, ‘click’, this.toggleClicked);
var triggers = $D.getElementsByClassName(‘mainNav’, ”, navDiv);
$E.on(triggers, ‘mouseover’, this.mouseOverMainNav);
}
};
$E.on(window, ‘load’, YSA.Nav.init, YSA.Nav, true);

// ]]>

Leave a Reply

avatar

This site uses Akismet to reduce spam. Learn how your comment data is processed.

  Subscribe  
Notify of

The articles by the Prisoners do not reflect the view of this website but are published intact as the prisoners write them, however comments are welcome