[DRE-commits] r5357 - in trunk/gemwatch: public views

Antonio Terceiro terceiro-guest at alioth.debian.org
Sun May 16 17:53:43 UTC 2010


Author: terceiro-guest
Date: 2010-05-16 17:53:41 +0000 (Sun, 16 May 2010)
New Revision: 5357

Modified:
   trunk/gemwatch/public/gemwatch.js
   trunk/gemwatch/views/layout.haml
Log:
Don't jquery just for focusing a text box



Modified: trunk/gemwatch/public/gemwatch.js
===================================================================
--- trunk/gemwatch/public/gemwatch.js	2010-05-16 17:43:47 UTC (rev 5356)
+++ trunk/gemwatch/public/gemwatch.js	2010-05-16 17:53:41 UTC (rev 5357)
@@ -1,3 +1,4 @@
-$(function() {
-  $('#gem').focus();
-});
+var gembox = document.getElementById('gem');
+if (gembox) {
+  gembox.focus();
+}

Modified: trunk/gemwatch/views/layout.haml
===================================================================
--- trunk/gemwatch/views/layout.haml	2010-05-16 17:43:47 UTC (rev 5356)
+++ trunk/gemwatch/views/layout.haml	2010-05-16 17:53:41 UTC (rev 5357)
@@ -10,7 +10,6 @@
           %img{ :src => asset_url("/gemwatch.png") }
       %div.content
         =yield
-    %script{:src => "http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js", :type => "text/javascript", :charset => "utf-8"}
     %script{:src => asset_url("/gemwatch.js"), :type => "text/javascript", :charset => "utf-8"}
     %div.footer
       %div




More information about the Pkg-ruby-extras-commits mailing list