/* Media ================================================== */ if(typeof VMM != 'undefined' && typeof VMM.Media == 'undefined') { // something = new VMM.Media(parent, w, h, {thedata}); VMM.Media = function(parent, w, h, thedata) { /* PRIVATE VARS ================================================== */ var data = {}; // HOLDS DATA var _valid = false; var config = { width: 720, height: 400, content_width: 720, content_height: 400, ease: "easeInOutExpo", duration: 1000, spacing: 15 }; /* ELEMENTS ================================================== */ var $media = ""; var $container = ""; var $mediacontainer = ""; var $mediaelement = ""; var layout = parent; // expecting media div if (w != null && w != "") {config.width = w}; if (h != null && h != "") {config.height = h}; /* if (typeof thedata != "undefined") { data = thedata; this.init(data); } */ /* PUBLIC FUNCTIONS ================================================== */ this.init = function(d) { if(typeof d != 'undefined') { this.setData(d); } else { trace("WAITING ON DATA"); } }; var build = function(media, caption, credit) { $media = VMM.appendAndGetElement(layout, "