function ZMWC_closeAllMainWindows()
{
    ZMWC_hide('ZMWC_successfulQueries')

    ZMWC_hide('ZMWC_unsuccessfulQueries')

    ZMWC_hide('ZMWC_messages')

    ZMWC_hide('ZMWC_watch')

    ZMWC_hide('ZMWC_globals')
}

function ZMWC_closeAllGlobalWindows()
{
    ZMWC_hide('ZMWC_cookie')

    ZMWC_hide('ZMWC_files')

    ZMWC_hide('ZMWC_get')

    ZMWC_hide('ZMWC_post')

    ZMWC_hide('ZMWC_server')

    ZMWC_hide('ZMWC_session')
}

function ZMWC_toggleMain(obj)
{

    if (!ZMWC_is_shown(obj)) {

        ZMWC_closeAllMainWindows()

        ZMWC_show(obj)

    } else {

        ZMWC_hide(obj)

    }

}

function ZMWC_toggleGlobal(obj)
{

    if (!ZMWC_is_shown(obj)) {

        ZMWC_closeAllGlobalWindows()

        ZMWC_show(obj)

    } else {

        ZMWC_hide(obj)

    }

}

function ZMWC_hide(obj)
{

    document.getElementById(obj).style.display = 'none'

}

function ZMWC_show(obj)
{

    document.getElementById(obj).style.display = 'block'

}

function ZMWC_is_hidden(obj)
{

    if (document.getElementById(obj).style.display == 'none') {

        return true

    }

    return false

}

function ZMWC_is_shown(obj)
{

    if (document.getElementById(obj).style.display == 'block') {

        return true

    }

    return false

}
