Ignore:
Timestamp:
2012-10-11T14:52:29+13:00 (12 years ago)
Author:
sjm84
Message:

Changed the slideshow to use more of the screen and reverting the page width change

Location:
main/trunk/greenstone3/web/interfaces/default
Files:
1 added
3 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/default/js/document_scripts.js

    r26302 r26305  
    12911291function showSlideShow()
    12921292{
    1293     var visible = $("#ssOption").attr('checked');
    1294     if(visible)
    1295     {
    1296         $("#gs-document").hide();
    1297         if(!($("#gs-slideshow").length))
    1298         {
    1299             var slideshowDiv = $("<div>", {id:"gs-slideshow"});
    1300             var loadingImage = $("<img>", {src:gs.imageURLs.loading});
    1301             slideshowDiv.append(loadingImage);
    1302            
    1303             $("#gs-document").after(slideshowDiv);
    1304            
    1305             retrieveImagesForSlideShow(function(imageIDArray)
    1306             {
    1307                 loadingImage.hide();
    1308                 if(imageIDArray && imageIDArray.length > 0)
    1309                 {
    1310                     var imageURLs = new Array();
    1311                     for(var i = 0; i < imageIDArray.length; i++)
     1293    $("#ssOption").attr('checked', false);
     1294    if(!($("#gs-slideshow").length))
     1295    {
     1296        var slideshowDiv = $("<div>", {id:"gs-slideshow"});
     1297        var loadingImage = $("<img>", {src:gs.imageURLs.loading});
     1298        slideshowDiv.append(loadingImage);
     1299       
     1300        $.blockUI({message: $(slideshowDiv), css:{top: "5%", left: "5%", width: "90%", height: "90%", overflow: "auto", cursor: "auto"}});
     1301       
     1302        retrieveImagesForSlideShow(function(imageIDArray)
     1303        {
     1304            loadingImage.hide();
     1305            if(imageIDArray && imageIDArray.length > 0)
     1306            {
     1307                var imageURLs = new Array();
     1308                for(var i = 0; i < imageIDArray.length; i++)
     1309                {
     1310                    if(imageIDArray[i].source && imageIDArray[i].source.search(/.*\.(gif|jpg|jpeg|png)$/) != -1)
    13121311                    {
    1313                         if(imageIDArray[i].source && imageIDArray[i].source.search(/.*\.(gif|jpg|jpeg|png)$/) != -1)
    1314                         {
    1315                             imageURLs.push(gs.collectionMetadata.httpPath + "/index/assoc/" + gs.documentMetadata.assocfilepath + "/" + imageIDArray[i].source);
    1316                         }
     1312                        imageURLs.push(gs.collectionMetadata.httpPath + "/index/assoc/" + gs.documentMetadata.assocfilepath + "/" + imageIDArray[i].source);
    13171313                    }
    1318                     new SlideShowWidget(slideshowDiv, imageURLs, imageIDArray);
    1319                 }
    1320             });
    1321         }
    1322         else
    1323         {
    1324             $("#gs-slideshow").show();
    1325         }
    1326        
    1327         if($("#zoomOptions").length)
    1328         {
    1329             $("#zoomOptions").hide();
    1330         }
     1314                }
     1315                new SlideShowWidget(slideshowDiv, imageURLs, imageIDArray);
     1316            }
     1317        });
    13311318    }
    13321319    else
    13331320    {
    1334         if($("#gs-slideshow").length)
    1335         {
    1336             $("#gs-slideshow").hide();
    1337         }
    1338         $("#gs-document").show();
    1339        
    1340         if($("#zoomOptions").length)
    1341         {
    1342             $("#zoomOptions").show();
    1343         }
     1321        $("#gs-slideshow").show();
     1322    }
     1323   
     1324    if($("#zoomOptions").length)
     1325    {
     1326        $("#zoomOptions").hide();
    13441327    }
    13451328}
     
    13841367    var _nextButton = $("<img>", {src:gs.imageURLs.next, style:"float:right; cursor:pointer;"});
    13851368    var _prevButton = $("<img>", {src:gs.imageURLs.prev, style:"float:left; cursor:pointer; display:none;"});
     1369    var _closeLink = $("<a href=\"javascript:$.unblockUI()\">Close Slideshow</a>");
    13861370    var _clearDiv = $("<div>", {style:"clear:both;"});
    13871371    var _currentIndex = 0;
    13881372   
    13891373    _navDiv.append(_nextButton);
     1374    _navDiv.append(_closeLink);
    13901375    _navDiv.append(_prevButton);
    13911376    _navDiv.append(_clearDiv);
     
    14181403                }
    14191404           
    1420                 _imageDiv.fadeOut(1000, function()
     1405                _imageDiv.fadeOut(500, function()
    14211406                {
    14221407                    _imageDiv.empty();
    14231408                    _imageDiv.append(_images[_currentIndex + 1]);
    14241409                    _currentIndex++;
    1425                     _imageDiv.fadeIn(1000, function()
     1410                    _imageDiv.fadeIn(500, function()
    14261411                    {
    14271412                        _inTransition = false;
     
    14491434                }
    14501435           
    1451                 _imageDiv.fadeOut(1000, function()
     1436                _imageDiv.fadeOut(500, function()
    14521437                {
    14531438                    _imageDiv.empty();
    14541439                    _imageDiv.append(_images[_currentIndex - 1]);
    14551440                    _currentIndex--;
    1456                     _imageDiv.fadeIn(1000, function()
     1441                    _imageDiv.fadeIn(500, function()
    14571442                    {
    14581443                        _inTransition = false;
     
    14801465            _inTransition = true;
    14811466            _currentIndex = index;
    1482             _imageDiv.fadeOut(1000, function()
     1467            _imageDiv.fadeOut(500, function()
    14831468            {
    14841469                _imageDiv.empty();
    14851470                _imageDiv.append(_images[_currentIndex]);
    1486                 _imageDiv.fadeIn(1000, function()
     1471                _imageDiv.fadeIn(500, function()
    14871472                {
    14881473                    _inTransition = false;
  • main/trunk/greenstone3/web/interfaces/default/style/core.css

    r26301 r26305  
    151151    position: relative;
    152152    margin: 0 auto 20px auto;
    153     width: 80%;
     153    max-width: 1000px;
    154154    padding: 0;
    155155    line-height: 120%;
     
    160160#topArea {
    161161    border: none;
    162     width: 80%;
     162    max-width: 1000px;
    163163    margin: 20px auto 0;
    164164}
     
    840840}
    841841
    842 #gs-slideshow{
    843     width:65%;
    844 }
    845 
    846842.slideshowImage{
    847843    width:100%;
  • main/trunk/greenstone3/web/interfaces/default/transform/layouts/header.xsl

    r26284 r26305  
    5656        <script type="text/javascript" src="interfaces/{$interface_name}/js/jquery-ui.min.js"><xsl:text> </xsl:text></script>
    5757        <script type="text/javascript" src="interfaces/{$interface_name}/js/jquery.themeswitcher.min.js"><xsl:text> </xsl:text></script>
     58        <script type="text/javascript" src="interfaces/{$interface_name}/js/jquery.blockUI.js"><xsl:text> </xsl:text></script>
    5859       
    5960        <script type="text/javascript" src="interfaces/{$interface_name}/js/direct-edit.js"><xsl:text> </xsl:text></script>
Note: See TracChangeset for help on using the changeset viewer.