﻿/**
 * Holds the list of page events
 **/
var PageEventQueue = {
    /**
     * An array for holding page events
     **/
    queue : Array(),
    /**
     * Adds a page event to the list of processable events
     **/
    add : function (f) {
    
        PageEventQueue.queue.push(f);
    },
    /**
     * Processes all events in the queue
     **/
    process : function (sender, args) {
        
        PageEventQueue.queue.each(function(f) {
            f(sender, args);
        });
    }
};
