﻿var comment_form_opening = 0;
var running = 0;

function ShowCommentForm()
{
    if(comment_form_opening != 0) return false;
    comment_form_opening = 1;
    
    $('div#profile-form-area').fadeIn(500, function() {
        comment_form_opening = 0;
    });
}


function HideUpdates()
{
    if(MyGoalBoard != null) MyGoalBoard.Hide();
    $('div#activity-list').slideUp(300, function() {
        $('#hide-updates-link').hide();
        $('#show-updates-link').show();
        
        if(MyGoalBoard != null)
        {
            MyGoalBoard.Refresh();
            MyGoalBoard.Show();
        }
        
    });
}

function ShowUpdates()
{
    if(MyGoalBoard != null) MyGoalBoard.Hide();
    $('div#activity-list').slideDown(300, function() {
        $('#hide-updates-link').show();
        $('#show-updates-link').hide();

        if(MyGoalBoard != null)
        {
            MyGoalBoard.Refresh();
            MyGoalBoard.Show();
        }
    });
}

function ShowCommentReply(id)
{
    $('div#ajax-form-' + id).fadeIn(200, function()
    {
        //do something
    });
}

function HideCommentReply(id)
{
    $('div#ajax-form-' + id).fadeOut(200, function()
    {
        //do something
    });
}
