backbone-baseview.js
function (event) {
            var args = slice.call(arguments, 1);
            var stopPropogation;
            var anscestor;
            args.unshift(event);
            args.push(this);
            anscestor = this;
            while (anscestor) {
                anscestor.trigger.apply(anscestor, args);
                stopPropogation = anscestor._stopPropogation;
                if (stopPropogation && stopPropogation[event]) {
                    stopPropogation[event] = false;
                    return this;
                }
                anscestor = anscestor.parentView;
            }
            return this;
        }
function (event) {
            var args = slice.call(arguments, 1);
            var stopPropogation;
            var anscestor;
            args.unshift(event);
            args.push(this);
            anscestor = this;
            while (anscestor) {
                anscestor.trigger.apply(anscestor, args);
                stopPropogation = anscestor._stopPropogation;
                if (stopPropogation && stopPropogation[event]) {
                    stopPropogation[event] = false;
                    return this;
                }
                anscestor = anscestor.parentView;
            }
            return this;
        }
function ( event ) { var args = slice . call ( arguments , 1 ) ; var stopPropogation ; var anscestor ; args . unshift ( event ) ; args . push ( this ) ; anscestor = this ; while ( anscestor ) { anscestor . trigger . apply ( anscestor , args ) ; stopPropogation = anscestor . _stopPropogation ; if ( stopPropogation && stopPropogation [ event ] ) { stopPropogation [ event ] = false ; return this ; } anscestor = anscestor . parentView ; } return this ; }
Like Backbone.trigger, except that this will not only use trigger
on the instance this method is invoked on, but also the instance's
'parentView', and the parentView's parentView, and so on.
Additional arguments beyond the event name will be passed
as arguments to the event handler functions. The view that
originated the bubbling event will automatically be tacked
on to the end of the arguments, so you can access it if needed.
@memberOf Backbone.BaseView#
@param {String} event The name of the event
@param {...Mixed} [arg] Argument be passed to event callbacks
@return {Backbone.BaseView}
Like Backbone . trigger except that this will not only use trigger on the instance this method is invoked on but also the instance s parentView and the parentView s parentView and so on . Additional arguments beyond the event name will be passed as arguments to the event handler functions . The view that originated the bubbling event will automatically be tacked on to the end of the arguments so you can access it if needed .