﻿/// <reference path="jquery-1.4.1-vsdoc.js" />

$(function () {
    // when we edit text in the boxes, hide the caption
    $(".jLabelField").each(function () {
        var textbox = $(".TextBox", this);
        textbox.focus(function () {
            textbox.select();
        });
        var notes = $(".Notifications .Note", this);
        // toggle visibility of notes
        var update = function () {
            var value = textbox.val();
            if (value.length == 0)
                notes.show();
            else
                notes.hide();
        }
        update();
        textbox.change(update);
        textbox.keyup(update);
    });

    $(".jDisableAutocomplete input").attr("autocomplete", "off");
});
