Version 3.3.4
This commit is contained in:
1 parent
78706903a2
commit
fb6b5baabc
2206 files changed
+409828
-382984
No files matched your search
@@ -129,10 +129,20 @@ _idx.prototype.board = {
|
||||
|
||||
// Get cookie
|
||||
var cookie = ipb.Cookie.get('toggleCats');
|
||||
|
||||
if( cookie == null ){
|
||||
cookie = $A();
|
||||
} else {
|
||||
cookie = cookie.split(',');
|
||||
_cookie = cookie.split(',');
|
||||
cookie = $A();
|
||||
|
||||
_cookie.each( function( item )
|
||||
{
|
||||
if ( item )
|
||||
{
|
||||
cookie.push( item );
|
||||
}
|
||||
} );
|
||||
}
|
||||
|
||||
Effect.toggle( wrapper, 'blind', {duration: 0.4, afterFinish: function(){ ipb.board.animating = false; } } );
|
||||
@@ -149,10 +159,33 @@ _idx.prototype.board = {
|
||||
$( catname ).addClassName('collapsed');
|
||||
ipb.board.animating = false;
|
||||
} });
|
||||
|
||||
cookie.push( catid );
|
||||
}
|
||||
|
||||
/* without not so hot in Chrome */
|
||||
_cookie = cookie;
|
||||
cookie = $A();
|
||||
|
||||
cookie = "," + cookie.uniq().without( remove ).join(',') + ",";
|
||||
_cookie.each( function( item )
|
||||
{
|
||||
ok = true;
|
||||
|
||||
remove.each( function( ritem )
|
||||
{
|
||||
if ( ritem == item )
|
||||
{
|
||||
ok = false;
|
||||
}
|
||||
} )
|
||||
|
||||
if ( ok === true )
|
||||
{
|
||||
cookie.push( item );
|
||||
}
|
||||
} );
|
||||
|
||||
cookie = "," + cookie.uniq().join(',') + ",";
|
||||
|
||||
ipb.Cookie.set('toggleCats', cookie, 1);
|
||||
|
||||
@@ -184,16 +217,9 @@ _idx.prototype.board = {
|
||||
{
|
||||
ipb.Cookie.set('hide_sidebar', 1, 1);
|
||||
|
||||
if( Prototype.Browser.WebKit ){
|
||||
// Chrome utterly fails to animate our ipsLayout styling. So we have to refresh the page.
|
||||
window.location.reload();
|
||||
}
|
||||
else
|
||||
{
|
||||
new Effect.Fade( $('index_stats'), { duration: 0.4, afterFinish: function(){
|
||||
new Effect.Morph( $('board_index'), { duration: 0.3, style:'no_sidebar' });
|
||||
} } );
|
||||
}
|
||||
new Effect.Fade( $('index_stats'), { duration: 0.4, afterFinish: function(){
|
||||
new Effect.Morph( $('board_index'), { duration: 0.3, style:'no_sidebar' });
|
||||
} } );
|
||||
|
||||
$('toggle_sidebar').update("«");
|
||||
}
|
||||
@@ -201,17 +227,11 @@ _idx.prototype.board = {
|
||||
{
|
||||
ipb.Cookie.set('hide_sidebar', 0, 1);
|
||||
|
||||
if( Prototype.Browser.WebKit ){
|
||||
window.location.reload();
|
||||
}
|
||||
else
|
||||
{
|
||||
new Effect.Morph( $('board_index'), { duration: 0.3, style:'force_sidebar', afterFinish: function(){
|
||||
new Effect.Appear( $('index_stats'), { duration: 0.4, afterFinish: function(){
|
||||
$('board_index').removeClassName('no_sidebar').removeClassName('force_sidebar');
|
||||
}});
|
||||
} } );
|
||||
}
|
||||
new Effect.Morph( $('board_index'), { duration: 0.3, style:'force_sidebar', afterFinish: function(){
|
||||
new Effect.Appear( $('index_stats'), { duration: 0.4, afterFinish: function(){
|
||||
$('board_index').removeClassName('no_sidebar').removeClassName('force_sidebar');
|
||||
}});
|
||||
} } );
|
||||
|
||||
$('toggle_sidebar').update("×");
|
||||
}
|
||||
@@ -224,7 +244,7 @@ _idx.prototype.board = {
|
||||
*/
|
||||
setUpSideBarBlocks: function()
|
||||
{
|
||||
if ( $('index_stats').visible() )
|
||||
if ( $('index_stats') && $('index_stats').visible() )
|
||||
{
|
||||
$$('#index_stats h3').each( function(h3)
|
||||
{
|
||||
@@ -298,7 +318,6 @@ _idx.prototype.board = {
|
||||
}
|
||||
|
||||
ipb.delegate.register(".ipsSidebar_trigger", ipb.board.toggleSideBarBlock);
|
||||
//ipb.board.resetSideBarHideOrNot(true);
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -312,19 +331,25 @@ _idx.prototype.board = {
|
||||
var remove = $A();
|
||||
cookie = ipb.Cookie.get('toggleSBlocks');
|
||||
|
||||
if( cookie == null )
|
||||
{
|
||||
if( cookie == null ){
|
||||
cookie = $A();
|
||||
}
|
||||
else
|
||||
{
|
||||
cookie = cookie.split(',');
|
||||
} else {
|
||||
_cookie = cookie.split(',');
|
||||
cookie = $A();
|
||||
|
||||
_cookie.each( function( item )
|
||||
{
|
||||
if ( item )
|
||||
{
|
||||
cookie.push( item );
|
||||
}
|
||||
} );
|
||||
}
|
||||
|
||||
/* Test for known class name */
|
||||
var top = elem.up('div');
|
||||
|
||||
moo = top.className.match('__xX([0-9А-Яа-яA-Za-z]+)');
|
||||
moo = top.className.match('__xX([0-9A-Za-z]+)');
|
||||
topId = moo[1];
|
||||
|
||||
block = top.down('._sbcollapsable');
|
||||
@@ -386,48 +411,32 @@ _idx.prototype.board = {
|
||||
Effect.toggle( block, 'blind', {duration: 0.4, afterFinish: function(){ ipb.board.animating = false; } } );
|
||||
}
|
||||
|
||||
cookie = "," + cookie.uniq().without( remove ).join(',') + ",";
|
||||
/* without not so hot in Chrome */
|
||||
_cookie = cookie;
|
||||
cookie = $A();
|
||||
|
||||
_cookie.each( function( item )
|
||||
{
|
||||
ok = true;
|
||||
|
||||
remove.each( function( ritem )
|
||||
{
|
||||
if ( ritem == item )
|
||||
{
|
||||
ok = false;
|
||||
}
|
||||
} )
|
||||
|
||||
if ( ok === true )
|
||||
{
|
||||
cookie.push( item );
|
||||
}
|
||||
} );
|
||||
|
||||
cookie = "," + cookie.uniq().join(',') + ",";
|
||||
|
||||
ipb.Cookie.set('toggleSBlocks', cookie, 1);
|
||||
//ipb.board.resetSideBarHideOrNot();
|
||||
}
|
||||
|
||||
/*resetSideBarHideOrNot: function( fromInit )
|
||||
{
|
||||
if ( ipb.board.count_hidden >= ipb.board.count_sbars )
|
||||
{
|
||||
|
||||
if ( fromInit)
|
||||
{
|
||||
//$('index_stats').hide();
|
||||
}
|
||||
else
|
||||
{
|
||||
//$('index_stats').fade();
|
||||
}
|
||||
|
||||
//$('categories').addClassName('no_sidebar');
|
||||
|
||||
if ( ! $('open_sidebar') )
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( fromInit)
|
||||
{
|
||||
//$('index_stats').show();
|
||||
}
|
||||
else
|
||||
{
|
||||
//$('index_stats').appear();
|
||||
}
|
||||
|
||||
//$('categories').removeClassName('no_sidebar');
|
||||
}
|
||||
}*/
|
||||
};
|
||||
|
||||
ipb.board.init();
|
||||
Reference in new issue
Block a user