r750 - in oipf: data js/impl view
Author: ygrego Date: 2015-01-30 16:49:04 +0000 (Fri, 30 Jan 2015) New Revision: 750 Url: http://forge.nuiton.org/projects/sandbox/repository/revisions/750 Log: Adding of data in a variable + all non-visuals objects of OipfObjectFactory became one of her properties + VideobroadcastObject is now a html object(Visual object) Modified: oipf/data/data.js oipf/js/impl/OipfObjectFactory.js oipf/js/impl/VideoBroadcastObject.js oipf/view/welcome.html Modified: oipf/data/data.js =================================================================== --- oipf/data/data.js 2015-01-30 09:26:49 UTC (rev 749) +++ oipf/data/data.js 2015-01-30 16:49:04 UTC (rev 750) @@ -1,4 +1,4 @@ -{ +var data = { "tv": { "-generator-info-name": "KaZeR's XMLTV", "-generator-info-url": "http://www.kazer.org", Modified: oipf/js/impl/OipfObjectFactory.js =================================================================== --- oipf/js/impl/OipfObjectFactory.js 2015-01-30 09:26:49 UTC (rev 749) +++ oipf/js/impl/OipfObjectFactory.js 2015-01-30 16:49:04 UTC (rev 750) @@ -26,10 +26,23 @@ init: function() { console.log("[INFO] constructor of OipfObjectFactory class called."); - this.applicationManagerObject = new ApplicationManagerObject(); - this.channelConfig = new ChannelConfig(); - this.searchManagerObject = new SearchManagerObject(); - this.remoteManagementObject = new RemoteManagementObject(); + //this.applicationManagerObject = new ApplicationManagerObject(); + //this.capabilitiesObject = new CapabilitiesObject(); + //this.codManagerObject = new CodManagerObject(); + //this.channelConfig = new ChannelConfig(); + //this.imsObject = new IMSObecjet(); + //this.mdtfObject = new MDTFObject(); + //this.notifSocketObject = new NotifSocket(); + //this.parentalControlManagerObject = new ParentalControlManagerObject(); + //this.recordingSchedulerObject = new RecordingSchedulerObject(); + //this.searchManagerObject = new SearchManagerObject(); + //this.configurationObject = new ConfigurationObject(); + //this.downloadManagerObject= new DownloadManagerObject(); + //this.downloadTriggerObject= new DownloadTriggerObject(); + //this.drmAgentObject= new DrmAgentObject(); + //this.gatewayInfoObject= new GatewayInfoObject(); + //this.remoteManagementObject = new RemoteManagementObject(); + //this.remoteControlFunctionObject = new RemoteControlFunctionObject(); }, /* @@ -41,6 +54,8 @@ */ applicationManagerObject: null, + capabilitiesObject: null, + codManagerObject: null, /*The ChannelConfig class provides the entry point for applications to get information about the list of channels @@ -71,7 +86,29 @@ * security requirements as defined in section 10. */ remoteManagementObject: null, + + remoteControlFunctionObject: null, + + imsObject : null, + + mdtfObject: null, + + notifSocketObject: null, + + parentalControlManagerObject: null, + + recordingSchedulerObject: null, + + configurationObject: null, + + downloadManagerObject: null, + + downloadTriggerObject: null, + + drmAgentObject: null, + gatewayInfoObject: null, + /* * Description: OITFs SHALL implement the application/oipfSearchManager embedded object. This object provides a * mechanism for applications to create and manage metadata searches. @@ -193,7 +230,7 @@ createCapabilitiesObject: function() { console.log("[INFO] createCapabilitiesObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(capabilities_dae_mime_type); + return this.capabilitiesObject; }, /*! @@ -223,7 +260,7 @@ createConfigurationObject: function() { console.log("[INFO] createConfigurationObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(configuration_dae_mime_type); + return this.configurationObject; }, /*! @@ -233,7 +270,7 @@ createDownloadManagerObject: function() { console.log("[INFO] createDownloadManagerObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(downloadManager_dae_mime_type); + return this.downloadManagerObject; }, /*! @@ -243,7 +280,7 @@ createDownloadTriggerObject: function() { console.log("[INFO] createDownloadTriggerObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(downloadTrigger_dae_mime_type); + return this.downloadTriggerObject; }, /*! @@ -253,7 +290,7 @@ createDrmAgentObject: function() { console.log("[INFO] createDrmAgentObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(drmAgent_dae_mime_type); + return this.drmAgentObject; }, /*! @@ -263,7 +300,7 @@ createGatewayInfoObject: function() { console.log("[INFO] createGatewayInfoObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(gatewayInfo_dae_mime_type); + return this.gatewayInfoObject; }, /*! @@ -273,7 +310,7 @@ createIMSObject: function() { console.log("[INFO] createIMSObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(ims_dae_mime_type); + return this.imsObject; }, /*! @@ -283,7 +320,7 @@ createMDTFObject: function() { console.log("[INFO] createMDTFObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(mdtf_dae_mime_type); + return this.mdtfObject; }, /*! @@ -293,7 +330,7 @@ createNotifSocketObject: function() { console.log("[INFO] createNotifSocketObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(notifSocket_dae_mime_type); + return this.notifSocketObject; }, /*! @@ -303,7 +340,7 @@ createParentalControlManagerObject: function() { console.log("[INFO] createParentalControlManangerObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(parentalControlManager_dae_mime_type); + return this.parentalControlManagerObject; }, /*! @@ -313,7 +350,7 @@ createRecordingSchedulerObject: function() { console.log("[INFO] createRecordingSchedulerObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(recordingScheduler_dae_mime_type); + return this.recordingSchedulerObject; }, /*! @@ -323,7 +360,7 @@ createRemoteControlFunctionObject: function() { console.log("[INFO] createRemoteControlFunctionObject() of OipfObjectFactory class called."); - return this.verifOipfObjectExisting(remoteControlFunction_dae_mime_type); + return this.remoteControlFunctionObject; }, /*! Modified: oipf/js/impl/VideoBroadcastObject.js =================================================================== --- oipf/js/impl/VideoBroadcastObject.js 2015-01-30 09:26:49 UTC (rev 749) +++ oipf/js/impl/VideoBroadcastObject.js 2015-01-30 16:49:04 UTC (rev 750) @@ -1,10 +1,8 @@ var VideoBroadcastObject = Class.extend({ - //Default value - width: 200, + width: null, - //Default value - heigth: 200, + heigth: null, playstate: 0, @@ -16,6 +14,21 @@ init: function() { console.log("[INFO] constructor of VideoBroadcast class called."); + + var proto = VideoBroadcastObject.prototype; + proto.createdCallback = function(){ + console.log("OK"); + //this.width= "128"; + //this.height= "128"; + this.align = "middle"; + this.style = "background-image:url(\"../view/img/video-broadcast.jpg\")"; + //this.data = "../view/img/video-broadcast.jpg"; + } + + document.registerElement('video-broadcast', { + prototype: proto, + extends: "object" + }); }, /*! Modified: oipf/view/welcome.html =================================================================== --- oipf/view/welcome.html 2015-01-30 09:26:49 UTC (rev 749) +++ oipf/view/welcome.html 2015-01-30 16:49:04 UTC (rev 750) @@ -1,9 +1,17 @@ <html> <head> <title>TestOIPFLib</title> - - </head> - <body> + <style> + body { + background-image: url("img/TV-T&PC.svg"); + background-repeat: no-repeat; + background-size: cover; + background-position: center; + } + </style> + + <script src="../js/lib/VisualClass.js" type="text/javascript"></script> + <script src="../js/lib/Class.js" type="text/javascript"></script> <script src="../data/data.js" type="text/javascript"></script> <script src="../js/impl/OipfObjectFactory.js" type="text/javascript"></script> <script src="../js/impl/ChannelConfig.js" type="text/javascript"></script> @@ -13,10 +21,30 @@ <script src="../js/test/test.js" type="text/javascript"></script> <script> testCreatingVidBroadObj(); - testCreatingSearchManagerObj(); - testCreatingChannelConfigObj(); + //document.body.innerHTML ="<object is='video-broadcast'></object>" + //testCreatingSearchManagerObj();<x-foo-with-markup><x-foo-with-markup/> + //testCreatingChannelConfigObj(); </script> + <script> + var XFooProto = Object.create(HTMLElement.prototype); + + XFooProto.createdCallback = function() { + //this.innerHTML = "<b>I'm an x-foo-with-markup!</b>";<object is="x-foo-with-markup"></object> + this.width= "128"; + this.height= "128"; + this.type="application/vnd.adobe.flash-movie"; + this.data= "/img/helloworld.swf"; + }; + + var XFoo = document.registerElement('x-foo-with-markup', {prototype: XFooProto, extends: "object"}); + + </script> + </head> + <body> + + <object is="video-broadcast"></object> + </body> </html> \ No newline at end of file
participants (1)
-
ygregoï¼ users.nuiton.org