ProspectDirector.Types.Core.ElementFill = Class.extend({

    init: function (options) {

        this.options = $.extend({
            element: null
        }, options);

    },

    //---------------------------
    //--- PROPERTIES
    //---------------------------

    get_element: function () {
        return this.options.element;
    },

    get_parent: function () {
        return this.get_element().parent();
    },

    //---------------------------
    //--- METHODS
    //---------------------------

    size: function () {

        var target = this.get_element(), 
            totalHeight = this.get_parent().outerHeight(),
            actualHeight = totalHeight;

        this.get_parent().children().each(function (index, element) {
            if (!$(element).is(target)) {
                actualHeight = actualHeight - $(element).outerHeight(true);
            }
        });

        this.get_element().height(actualHeight);

    }

});