Revision: 2540
Author: seba.wagner
Date: Tue Oct 27 02:28:20 2009
Log: Make template paths dynamic to use it in both scenarios, as .war or  
red5-webapp
http://code.google.com/p/openmeetings/source/detail?r=2540

Modified:
   
/trunk/singlewebapp/WebContent/openmeetings/modules/conference/moderation/moderationPanel.lzx
   
/trunk/singlewebapp/WebContent/openmeetings/modules/sharing/sharingSession.lzx
   
/trunk/singlewebapp/src/app/org/openmeetings/servlet/outputhandler/ScreenRequestHandler.java
  /trunk/singlewebapp/src/templates/screencast_jrdesktop.vm
  /trunk/singlewebapp/src/templates/screencast_odsp_sharertemplate.vm
  /trunk/singlewebapp/src/templates/screencast_odsp_viewertemplate.vm
  /trunk/singlewebapp/src/templates/screencast_template.vm

=======================================
---  
/trunk/singlewebapp/WebContent/openmeetings/modules/conference/moderation/moderationPanel.lzx
    
Mon Oct 26 05:00:12 2009
+++  
/trunk/singlewebapp/WebContent/openmeetings/modules/conference/moderation/moderationPanel.lzx
    
Tue Oct 27 02:28:20 2009
@@ -77,6 +77,7 @@
                      +'&sid='+canvas.sessionId
                      +'&red5httpport='+canvas.red5httpport
                      +'&publicSID='+canvas.publicSID
+                    +'&httpRootKey='+canvas.httpRootKey
                      +'&languageAsString='+hib.userlang
                      +'&record='+record;

=======================================
---  
/trunk/singlewebapp/WebContent/openmeetings/modules/sharing/sharingSession.lzx  
 
Mon Oct 12 07:45:40 2009
+++  
/trunk/singlewebapp/WebContent/openmeetings/modules/sharing/sharingSession.lzx  
 
Tue Oct 27 02:28:20 2009
@@ -176,6 +176,7 @@
              var downloadurl  
= 'http://'+canvas.rtmphostlocal+':'+canvas.red5httpport
                  +canvas.httpRootKey+'ScreenRequestHandler?'
                  +'rtmphostlocal='+canvas.rtmphostlocal
+                +'&httpRootKey='+canvas.httpRootKey
                  +'&room='+hib.currentroomid
                  +'&domain='+hib.conferencedomain
                  +'&sid='+canvas.sessionId
=======================================
---  
/trunk/singlewebapp/src/app/org/openmeetings/servlet/outputhandler/ScreenRequestHandler.java
     
Mon Oct 26 08:27:13 2009
+++  
/trunk/singlewebapp/src/app/org/openmeetings/servlet/outputhandler/ScreenRequestHandler.java
     
Tue Oct 27 02:28:20 2009
@@ -126,7 +126,7 @@

                                String publicSID = 
httpServletRequest.getParameter("publicSID");
                                if (publicSID == null) {
-                                       log.error("publicSID is empty: 
"+publicSID);
+                                       new Exception("publicSID is empty: 
"+publicSID);
                                        return null;
                                }

@@ -135,40 +135,46 @@

                                String domain = 
httpServletRequest.getParameter("domain");
                                if(domain == null) {
-                                       log.error("domain is empty: "+domain);
+                                       new Exception("domain is empty: 
"+domain);
                                        return null;
                                }

                                String languageAsString =  
httpServletRequest.getParameter("languageAsString");
                                if(languageAsString == null) {
-                                       log.error("languageAsString is empty: 
"+domain);
+                                       new Exception("languageAsString is 
empty: "+domain);
                                        return null;
                                }
                                Long language_id = 
Long.parseLong(languageAsString);

                                String rtmphostlocal =  
httpServletRequest.getParameter("rtmphostlocal");
                                if (rtmphostlocal == null) {
-                                       log.error("rtmphostlocal is empty: 
"+rtmphostlocal);
+                                       new Exception("rtmphostlocal is empty: 
"+rtmphostlocal);
                                        return null;
                                }

                                String red5httpport = 
httpServletRequest.getParameter("red5httpport");
                                if (red5httpport == null) {
-                                       log.error("red5httpport is empty: 
"+red5httpport);
+                                       new Exception("red5httpport is empty: 
"+red5httpport);
                                        return null;
                                }

                                String record = 
httpServletRequest.getParameter("record");
                                if (record == null) {
-                                       log.error("recorder is empty: ");
+                                       new Exception("recorder is empty: ");
                                        record = "no";
                                }

                                String mode = 
httpServletRequest.getParameter("mode");
                                if (mode == null) {
-                                       log.error("mode is empty: ");
+                                       new Exception("mode is empty: ");
                                        mode = "sharer";
                                }
+
+                               String httpRootKey = 
httpServletRequest.getParameter("httpRootKey");
+                               if (httpRootKey == null) {
+                                       new Exception("httpRootKey is empty 
could not start sharer");
+                                       return null;
+                               }

                                //make a complete name out of 
domain(organisation) + roomname
                                String roomName = domain+"_"+room;
@@ -181,7 +187,18 @@
                                //String jnlpString =  
ScreenCastTemplate.getInstance(current_dir).getScreenTemplate(rtmphostlocal,  
red5httpport, sid, room, domain);
                                ctx.put("rtmphostlocal", rtmphostlocal); 
//rtmphostlocal
                            ctx.put("red5httpport", red5httpport); 
//red5httpport
-                           ctx.put("webAppRootKey", "openmeetings"); //TODO: 
Query  
webAppRootKey by Servlet
+
+                           System.out.println("httpRootKey "+httpRootKey);
+
+                           String codebase  
= "http://"+rtmphostlocal+":"+red5httpport+httpRootKey+"screen";;
+
+                           ctx.put("codebase", codebase);
+
+                           String httpSharerURL = 
"http://"+rtmphostlocal+":"+red5httpport +  
httpRootKey + "ScreenServlet";
+
+                           ctx.put("webAppRootKey", httpRootKey);
+                           ctx.put("httpSharerURL", httpSharerURL);
+
                            ctx.put("SID", sid);
                            ctx.put("ROOM", room);
                            ctx.put("DOMAIN", domain);
=======================================
--- /trunk/singlewebapp/src/templates/screencast_jrdesktop.vm   Wed Oct 14  
08:14:22 2009
+++ /trunk/singlewebapp/src/templates/screencast_jrdesktop.vm   Tue Oct 27  
02:28:20 2009
@@ -1,6 +1,7 @@
  <?xml version="1.0" encoding="utf-8"?>
-<!-- Web Start Deployment Template $webAppRootKey/ => is obsolete as we  
deploy into ROOT -->
-<jnlp spec="1.0+" codebase="http://$rtmphostlocal:$red5httpport/screen";>
+<!-- Web Start Deployment Template $webAppRootKey/ => is either / in case
+its .war or /openmeetings/ in case its a native red5 webapp-->
+<jnlp spec="1.0+"  
codebase="http://$rtmphostlocal:$red5httpport$webAppRootKeyscreen";>
        <information>
                <title>ScreenViewer Client Application</title>
                <vendor>Openmeetings</vendor>
=======================================
--- /trunk/singlewebapp/src/templates/screencast_odsp_sharertemplate.vm Wed  
Oct 14 08:14:22 2009
+++ /trunk/singlewebapp/src/templates/screencast_odsp_sharertemplate.vm Tue  
Oct 27 02:28:20 2009
@@ -1,6 +1,7 @@
  <?xml version="1.0" encoding="utf-8"?>
-<!-- Web Start Deployment Template $webAppRootKey/ => is obsolete as we  
deploy into ROOT -->
-<jnlp spec="1.0+" codebase="http://$rtmphostlocal:$red5httpport/screen";>
+<!-- Web Start Deployment Template $webAppRootKey/ => is either / in case
+its .war or /openmeetings/ in case its a native red5 webapp-->
+<jnlp spec="1.0+" codebase="$codebase">
        <information>
                <title>ScreenViewer Client Application</title>
                <vendor>Openmeetings</vendor>
=======================================
--- /trunk/singlewebapp/src/templates/screencast_odsp_viewertemplate.vm Wed  
Oct 14 08:14:22 2009
+++ /trunk/singlewebapp/src/templates/screencast_odsp_viewertemplate.vm Tue  
Oct 27 02:28:20 2009
@@ -1,6 +1,7 @@
  <?xml version="1.0" encoding="utf-8"?>
-<!-- Web Start Deployment Template $webAppRootKey/ => is obsolete as we  
deploy into ROOT -->
-<jnlp spec="1.0+" codebase="http://$rtmphostlocal:$red5httpport/screen";>
+<!-- Web Start Deployment Template $webAppRootKey/ => is either / in case
+its .war or /openmeetings/ in case its a native red5 webapp-->
+<jnlp spec="1.0+" codebase="$codebase">
        <information>
                <title>ScreenViewer Client Application</title>
                <vendor>Openmeetings</vendor>
=======================================
--- /trunk/singlewebapp/src/templates/screencast_template.vm    Wed Oct 14  
08:14:22 2009
+++ /trunk/singlewebapp/src/templates/screencast_template.vm    Tue Oct 27  
02:28:20 2009
@@ -1,6 +1,7 @@
  <?xml version="1.0" encoding="utf-8"?>
-<!-- Web Start Deployment Template $webAppRootKey/ => is obsolete as we  
deploy into ROOT -->
-<jnlp spec="1.0+" codebase="http://$rtmphostlocal:$red5httpport/screen";>
+<!-- Web Start Deployment Template $webAppRootKey/ => is either / in case
+its .war or /openmeetings/ in case its a native red5 webapp-->
+<jnlp spec="1.0+" codebase="$codebase">
        <information>
                <title>ScreenViewer Client Application</title>
                <vendor>Openmeetings</vendor>
@@ -25,7 +26,7 @@
          <jar href="jta.jar"/>
      </resources>
      <application-desc  
main-class="org.openmeetings.webstart.gui.StartScreen">
-        
<argument>http://$rtmphostlocal:$red5httpport/$webAppRootKey/ScreenServlet</argument>
+       <argument>$httpSharerURL</argument>
        <argument>$SID</argument>
        <argument>$ROOM</argument>
        <argument>$DOMAIN</argument>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"OpenMeetings developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/openmeetings-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to