Changeset 81
- Timestamp:
- 05/01/08 21:36:23 (2 months ago)
- Files:
-
- trunk/trac/trac/htdocs/js/keyboard_nav.js (modified) (2 diffs)
- trunk/trac/trac/templates/layout.html (modified) (1 diff)
- trunk/trac/trac/templates/theme.html (modified) (1 diff)
- trunk/trac/trac/versioncontrol/web_ui/browser.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/trac/trac/htdocs/js/keyboard_nav.js
r61 r81 1 1 (function($){ 2 2 var SELECTED_FILE_ELEM = null; 3 var ENABLE_KEY_NAV = true;4 3 5 4 $(document).keydown(function(event) { 6 if (!ENABLE_KEY_NAV)7 return true;8 5 var selection = SELECTED_FILE_ELEM; 9 6 switch (event.keyCode) { … … 49 46 return false; 50 47 }); 51 52 $(function() {53 $('a,input,select,textarea,button')54 .focus(function(event) {55 ENABLE_KEY_NAV = false;56 })57 .blur(function(event) {58 ENABLE_KEY_NAV = true;59 });60 });61 48 })(jQuery); trunk/trac/trac/templates/layout.html
r61 r81 29 29 </head></py:match> 30 30 31 <div py:def="navigation(category)" id="${category}" class="nav"> 32 <ul py:if="chrome.nav[category]"> 33 <li py:for="idx, item in enumerate(chrome.nav[category])" 34 class="${classes(first_last(idx, chrome.nav[category]), active=item.active)}">${item.label}</li> 35 </ul> 36 </div> 37 31 38 <py:match path="body" once="true"><body> 32 39 ${select('*|text()')} 40 41 <script type="text/javascript" py:if="chrome.late_links"> 42 <py:for each="link in chrome.late_links.get('stylesheet')"> 43 jQuery.loadStyleSheet("${link.href}", "${link.title}"); 44 </py:for> 45 </script> 46 <script py:for="script in chrome.late_scripts" 47 type="${script.type}" src="${script.href}"></script> 33 48 34 <script type="text/javascript" py:if="chrome.late_links"> 35 <py:for each="link in chrome.late_links.get('stylesheet')"> 36 jQuery.loadStyleSheet("${link.href}", "${link.title}"); 37 </py:for> 38 </script> 39 <script py:for="script in chrome.late_scripts" 40 type="${script.type}" src="${script.href}"></script> 41 42 <div id="altlinks" py:if="'alternate' in chrome.links"> 43 <h3>Download in other formats:</h3> 44 <ul> 45 <li py:for="idx, link in enumerate(chrome.links.alternate)" 46 class="${first_last(idx, chrome.links.alternate)}"> 47 <a rel="nofollow" href="${link.href}" class="${link['class']}" 48 py:content="link.title" /> 49 </li> 50 </ul> 51 </div> 52 </body></py:match> 53 49 <div id="altlinks" py:if="'alternate' in chrome.links"> 50 <h3>Download in other formats:</h3> 51 <ul> 52 <li py:for="idx, link in enumerate(chrome.links.alternate)" 53 class="${first_last(idx, chrome.links.alternate)}"> 54 <a rel="nofollow" href="${link.href}" class="${link['class']}" 55 py:content="link.title" /> 56 </li> 57 </ul> 58 </div> 59 </body></py:match> 60 61 <xi:include href="$chrome.theme"><xi:fallback /></xi:include> 54 62 <xi:include href="$chrome.theme"><xi:fallback /></xi:include> 55 63 <xi:include href="site.html"><xi:fallback /></xi:include> trunk/trac/trac/templates/theme.html
r61 r81 6 6 xmlns:py="http://genshi.edgewall.org/" 7 7 py:strip=""> 8 9 <div py:def="navigation(category)" id="${category}" class="nav"> 10 <ul py:if="chrome.nav[category]"> 11 <li py:for="idx, item in enumerate(chrome.nav[category])" 12 class="${classes(first_last(idx, chrome.nav[category]), active=item.active)}">${item.label}</li> 13 </ul> 14 </div> 15 16 <py:match path="body" once="true" buffer="false"><body> 8 <py:match path="body" once="true"><body> 17 9 <div id="banner"> 18 10 <div id="header" py:choose=""> trunk/trac/trac/versioncontrol/web_ui/browser.py
r61 r81 386 386 href=req.href.browser(node.created_path, 387 387 rev=node.rev, 388 annotate= 'blame'))388 annotate=1)) 389 389 add_ctxtnav(req, _('Revision Log'), 390 390 href=req.href.log(path, rev=rev))