/**
 * @file       home.js
 * @author     Pavel Sokolov
 * @brief      TurnAges home page interface management operations
 *
 * Copyright (C) 2007-2010, TurnAges.com.
 *
 * The copyright notice above does not evidence any actual or intended publication of such 
 * source code. The code contains Edge Beyond Confidential Proprietary Information.
 */
 
function toggleLayer(id0, id1) {
    var c = document.getElementById(id0);
    c.style.display = 'none';

    c = document.getElementById(id1);
    c.style.display = 'block';
}

function toggleRatings(id) {
    if (typeof this.cRat === 'undefined') {
        this.cRat = 0;
    }
    
    toggleLayer("rat"+this.cRat, "rat"+id);

    this.cRat = id;
    
    return false;
};

function toggleNewsbit(id) {
    if (typeof this.cNBit === 'undefined') {
        this.cNBit = 0;
    }
    
    toggleLayer("nbit"+this.cNBit, "nbit"+id);
    this.cNBit = id;
    
    return false;
};

function toggleAbout(id) {
    if (typeof this.cAbout === 'undefined') {
        this.cAbout = 0;
    }
    
    toggleLayer("about"+this.cAbout, "about"+id);
    this.cAbout = id;
    
    return false;
};

function openWnd(n, w, h) {
    var newwindow=window.open(n,"name", "height="+(h+10)+",width="+(w+10));
    return false;
};