Author: buildbot
Date: Thu May  1 12:59:09 2014
New Revision: 907629

Log:
Staging update by buildbot for ooo-site

Modified:
    websites/staging/ooo-site/trunk/cgi-bin/   (props changed)
    websites/staging/ooo-site/trunk/content/   (props changed)
    websites/staging/ooo-site/trunk/content/download/test/download.js

Propchange: websites/staging/ooo-site/trunk/cgi-bin/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Thu May  1 12:59:09 2014
@@ -1 +1 @@
-1591642
+1591643

Propchange: websites/staging/ooo-site/trunk/content/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Thu May  1 12:59:09 2014
@@ -1 +1 @@
-1591642
+1591643

Modified: websites/staging/ooo-site/trunk/content/download/test/download.js
==============================================================================
--- websites/staging/ooo-site/trunk/content/download/test/download.js (original)
+++ websites/staging/ooo-site/trunk/content/download/test/download.js Thu May  
1 12:59:09 2014
@@ -2,9 +2,10 @@
  * Overview of all functions defined below
  * ---------------------------------------
  * function getLanguage   ()
- * function hasMirrorLink ( rel_mode )
+ * function hasMirrorLink ()
  * function getLink       ( rel_mode )
- * function getPlatform   ( rel_mode )
+ * function getPlatform   ()
+ * function getFilesize   ()
  * function openItem      ( itemid, uri )
  */
 
@@ -132,42 +133,14 @@ function getLanguage() {
  * Get flag for mirror link
  * Depends on array-list
  */
-function hasMirrorLink( rel_mode ) {
-
-       if ( rel_mode == 1 ) {
-               // Release mode
-               // First check if the Beta release languages (not available as 
current stable release !) are set in browser
-               if ( LANG_ISO == "bg" || LANG_ISO == "da" || LANG_ISO == "hi" 
|| LANG_ISO == "nb" || LANG_ISO == "th" ) {
-                       SOURCEFORGE     = false;
-                       OTHER           = true;
-                       ARCHIVE         = false;
-                       ERROR           = true;
-                       return false;
-               }
-               // Check the flag in "languages.js", 'y' -> provide download 
link, 'n' -> redirect to alternative webpage
-               if ( LANG_ARRAY[ 3 ] == 'y' ) {
-                       return true;
-               } else {
-                       ERROR = true;
-                       return false;
-               }
-       } else {
-               // Beta release mode
-               // Check the flag in "languages.js", 'y' -> provide download 
link, 'n' -> redirect to alternative webpage
-               if ( LANG_ARRAY[ 3 ] == 'y' ) {
-                       return true;
-               } else {
-                       ERROR = true;
-                       return false;
-               }
-       }
-/*
-       if ( LANG_ARRAY[ 3 ] == 'y' )
+function hasMirrorLink() {
+       // Check the flag in "languages.js", 'y' -> provide download link, 'n' 
-> redirect to alternative webpage
+       if ( LANG_ARRAY[ 3 ] == 'y' ) {
                return true;
-       else
+       } else {
                ERROR = true;
                return false;
-*/
+       }
 }
 
 /*
@@ -182,9 +155,9 @@ function getLink( rel_mode ) {
                rel_mode = 1;
 
        getLanguage();
-       getPlatform( rel_mode );
-       if ( hasMirrorLink( rel_mode ) ) {
-               getFilesize( rel_mode );
+       getPlatform();
+       if ( hasMirrorLink() ) {
+               getFilesize();
        }
        /*
        if ( NL_LANGUAGE == "" )
@@ -197,7 +170,7 @@ function getLink( rel_mode ) {
        */
 
        // If language is supported, then provide a download link. 
-       if ( hasMirrorLink( rel_mode ) ) {
+       if ( hasMirrorLink() ) {
                // Release mode
                if ( rel_mode == 1 ) {
                        // If platform is too old, then provide a general 
download link to the archive.
@@ -270,12 +243,11 @@ function getLink( rel_mode ) {
                        }
 
                        // If platform was recognized, assemble the filenames 
for download and checksums
-
-                       // FILENAME     = "Apache_OpenOffice_" + VERSION + "_" 
+ URL_PLATFORM + "_" + LANG_ISO;
-                       // FILENAME     = FILENAME + EXTENSION;
+                       FILENAME        = "Apache_OpenOffice_" + VERSION + "_" 
+ URL_PLATFORM + "_" + LANG_ISO;
+                       FILENAME        = FILENAME + EXTENSION;
 
                        // Assign the file name (column 3) from the release 
matrix of language and platform
-                       FILENAME        = release_matrix[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ][ 3 ];
+                       // FILENAME     = release_matrix_410[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ][ 3 ];
 
                        // LINK = SOURCEFORGE_BASE_URL + LANG_ISO + 
"/Apache_OpenOffice_" + VERSION + "_";
                        // LINK = LINK + URL_PLATFORM + "_" + LANG_ISO + 
EXTENSION + "/download";
@@ -337,8 +309,13 @@ function getLink( rel_mode ) {
                                ERROR           = true;
                                return LINK;
                        }
+
+                       // If platform was recognized, assemble the filenames 
for download and checksums
+                       FILENAME        = "Apache_OpenOffice_" + VERSION + "_" 
+ URL_PLATFORM + "_" + LANG_ISO;
+                       FILENAME        = FILENAME + EXTENSION;
+
                        // Assign the file name (column 3) from the release 
matrix of language and platform
-                       FILENAME        = release_matrix_beta[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ][ 3 ];
+                       // FILENAME     = release_matrix_410_beta[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ][ 3 ];
 
                        // LINK = BETA_SOURCEFORGE_BASE_URL + LANG_ISO + 
"/Apache_OpenOffice_Beta_" + VERSION + "_";
                        // LINK = LINK + URL_PLATFORM + "_" + LANG_ISO + 
EXTENSION + "/download";
@@ -378,7 +355,7 @@ function getLink( rel_mode ) {
  * Get platform of browser
  * Depends on internal browser data
  */
-function getPlatform( rel_mode ) {
+function getPlatform() {
        // For more help or data see: "http://www.useragentstring.com";
 
        var os          = navigator.platform.toLowerCase();     // Get the 
platform string in lower cases
@@ -525,8 +502,7 @@ function getPlatform( rel_mode ) {
                     ua.indexOf( "10.3"         ) != -1 ||
                     ua.indexOf( "10_3"         ) != -1 ) {     UI_PLATFORM     
= "Mac OS X (10.6 or older)";
                                                                URL_PLATFORM    
= "MacOS_x86_install";
-                                                               if ( rel_mode > 
0 )
-                                                                       
OLD_PLATFORM = true;
+                                                               OLD_PLATFORM    
= true;
                }
          } 
        } 
@@ -544,7 +520,7 @@ function getPlatform( rel_mode ) {
  * Get file size for download file
  * Depends on array-list
  */
-function getFilesize( rel_mode ) {
+function getFilesize() {
        // Depending on $URL_PLATFORM assign the platform position of the 
release matrix
        switch ( URL_PLATFORM ) {
                case "Linux_x86-64_install-deb":
@@ -574,19 +550,10 @@ function getFilesize( rel_mode ) {
 
        // If a platform was found and no error occurred, assign the array data 
and filesize from the release matrix
        if ( RELEASE_MATRIX_PLATFORM_POS > -1 && !ERROR ) {
-               if ( rel_mode == 1 ) {
-                       // Release mode
-                       // Assign all values from the release matrix of 
language and platform
-                       RELEASE_MATRIX_PLATFORM = release_matrix[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ];
-                       // Assign the file size (column 2) from the release 
matrix of language and platform
-                       FILESIZE                = release_matrix[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ][ 2 ];
-               } else {
-                       // Beta release mode
-                       // Assign all values from the release matrix of 
language and platform
-                       RELEASE_MATRIX_PLATFORM = release_matrix_beta[ LANG_ISO 
][ RELEASE_MATRIX_PLATFORM_POS ];
-                       // Assign the file size (column 2) from the release 
matrix of language and platform
-                       FILESIZE                = release_matrix_beta[ LANG_ISO 
][ RELEASE_MATRIX_PLATFORM_POS ][ 2 ];
-               }
+               // Assign all values from the release matrix of language and 
platform
+               RELEASE_MATRIX_PLATFORM = release_matrix_410[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ];
+               // Assign the file size (column 2) from the release matrix of 
language and platform
+               FILESIZE                = release_matrix_410[ LANG_ISO ][ 
RELEASE_MATRIX_PLATFORM_POS ][ 2 ];
        } else {
                ERROR    = true;
                FILESIZE = 0;


Reply via email to