Upgrade to jQuery 1.3. Fix problem where .show() was changing toolbar display attrib...
authorMichael Ang <mang@archive.org>
Fri, 26 Jun 2009 22:51:45 +0000 (22:51 +0000)
committerMichael Ang <mang@archive.org>
Fri, 26 Jun 2009 22:51:45 +0000 (22:51 +0000)
GnuBook/GnuBook.js
GnuBookIA/inc/GnuBook.inc

index 365ceaf..f72c9d4 100644 (file)
@@ -1,5 +1,5 @@
 /*
-Copyright(c)2008 Internet Archive. Software license AGPL version 3.
+Copyright(c)2008-2009 Internet Archive. Software license AGPL version 3.
 
 This file is part of GnuBook.
 
@@ -1918,8 +1918,8 @@ GnuBook.prototype.initToolbar = function(mode, ui) {
     jToolbar.append("<span id='GBtoolbarbuttons' style='float: right'>"
         + "<button class='GBicon rollover embed' />"
         + "<form class='GBpageform' action='javascript:' onsubmit='gb.jumpToPage(this.elements[0].value)'> <span class='label'>Page:<input id='GBpagenum' type='text' size='3' onfocus='gb.autoStop();'></input></span></form>"
-        + "<div class='GBtoolbarmode2' style='display: inline'><button class='GBicon rollover book_leftmost' /><button class='GBicon rollover book_left' /><button class='GBicon rollover book_right' /><button class='GBicon rollover book_rightmost' /></div>"
-        + "<div class='GBtoolbarmode1' style='display: hidden'><button class='GBicon rollover book_top' /><button class='GBicon rollover book_up' /> <button class='GBicon rollover book_down' /><button class='GBicon rollover book_bottom' /></div>"
+        + "<div class='GBtoolbarmode2' style='display: none'><button class='GBicon rollover book_leftmost' /><button class='GBicon rollover book_left' /><button class='GBicon rollover book_right' /><button class='GBicon rollover book_rightmost' /></div>"
+        + "<div class='GBtoolbarmode1' style='display: none'><button class='GBicon rollover book_top' /><button class='GBicon rollover book_up' /> <button class='GBicon rollover book_down' /><button class='GBicon rollover book_bottom' /></div>"
         + "<button class='GBicon rollover play' /><button class='GBicon rollover pause' style='display: none' /></span>");
 
     this.bindToolbarNavHandlers(jToolbar);
@@ -1966,11 +1966,11 @@ GnuBook.prototype.switchToolbarMode = function(mode) {
     if (1 == mode) {
         // 1-up     
         $('#GBtoolbar .GBtoolbarmode2').hide();
-        $('#GBtoolbar .GBtoolbarmode1').css('display', 'inline').show();
+        $('#GBtoolbar .GBtoolbarmode1').show().css('display', 'inline');
     } else {
         // 2-up
         $('#GBtoolbar .GBtoolbarmode1').hide();
-        $('#GBtoolbar .GBtoolbarmode2').css('display', 'inline').show();
+        $('#GBtoolbar .GBtoolbarmode2').show().css('display', 'inline');
     }
 }
 
index d01ebfe..a7eda5a 100644 (file)
@@ -82,7 +82,7 @@ class GnuBook
 <? if ($uimode == "embed") { ?>
     <link rel="stylesheet" type="text/css" href="/bookreader/GnuBookEmbed.css?v=<? echo($version); ?>">
 <? } /* uimode */ ?>
-    <script src="http://www.archive.org/includes/jquery-1.2.6.min.js" type="text/javascript"></script>
+    <script src="/includes/jquery-1.3.2.min.js" type="text/javascript"></script>
         <script type="text/javascript" src="/bookreader/GnuBook.js?v=<? echo($version); ?>"></script>
     <script type="text/javascript" src="/bookreader/jquery.easing.1.3.js"></script>
 </head>