r97563 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r97562‎ | r97563 | r97564 >
Date:21:49, 19 September 2011
Author:preilly
Status:old (Comments)
Tags:
Comment:
remove search based functions
Modified paths:
  • /branches/wmf/1.17wmf1/extensions/MobileFrontend/javascripts/application.js (modified) (history)

Diff [purge]

Index: branches/wmf/1.17wmf1/extensions/MobileFrontend/javascripts/application.js
@@ -1,32 +1,3 @@
2 -var search = document.getElementById( 'search' );
3 -var clearSearch = document.getElementById( 'clearsearch' );
4 -
5 -initClearSearchLink();
6 -
7 -function initClearSearchLink() {
8 - clearSearch.setAttribute( 'title','Clear' );
9 - clearSearch.addEventListener( 'mousedown', clearSearchBox, true );
10 - search.addEventListener( 'keyup', _handleClearSearchLink, false );
11 -}
12 -
13 -function _handleClearSearchLink() {
14 - if ( clearSearch ) {
15 - if ( search.value.length > 0 ) {
16 - clearSearch.style.display = 'block';
17 - } else {
18 - clearSearch.style.display = 'none';
19 - }
20 - }
21 -}
22 -
23 -function clearSearchBox( event ) {
24 - search.value = '';
25 - clearSearch.style.display = 'none';
26 - if ( event ) {
27 - event.preventDefault();
28 - }
29 -}
30 -
312 // I don't think this makes sense. Loading this here means that this button
323 // won't function until the page is loaded. It would probably be an
334 // improvement to just attach an onclick straight into the html.
@@ -112,4 +83,4 @@
11384 var s = document.getElementById( d[i] + section_id ).style;
11485 s.display = s.display == 'block' ? 'none' : 'block';
11586 }
116 -}
\ No newline at end of file
 87+}

Follow-up revisions

RevisionCommit summaryAuthorDate
r976801.18wmf1 Merge r97533, r97556, r97563, r97592, r97654reedy23:14, 20 September 2011

Comments

#Comment by 😂 (talk | contribs)   21:49, 19 September 2011

Is this a followup to a trunk rev?

Status & tagging log