From: Chad Horohoe Date: Fri, 22 Aug 2008 16:00:04 +0000 (+0000) Subject: Tweak to UI for Special:Watchlist. Put a fieldset around the options. Looks cleaner... X-Git-Tag: 1.31.0-rc.0~45715 X-Git-Url: http://git.cyclocoop.org/%24action?a=commitdiff_plain;h=8ed87bb509daa295b7844e3d1d3cf260eacea405;p=lhc%2Fweb%2Fwiklou.git Tweak to UI for Special:Watchlist. Put a fieldset around the options. Looks cleaner to me :) --- diff --git a/includes/specials/SpecialWatchlist.php b/includes/specials/SpecialWatchlist.php index e67c4fdd76..a500ab0aed 100644 --- a/includes/specials/SpecialWatchlist.php +++ b/includes/specials/SpecialWatchlist.php @@ -241,7 +241,7 @@ function wfSpecialWatchlist( $par ) { ); } - $wgOut->addHTML( "\n" . wlCutoffLinks( $days, 'Watchlist', $nondefaults ) . "
\n" ); + $cutofflinks = "\n" . wlCutoffLinks( $days, 'Watchlist', $nondefaults ) . "
\n"; # Spit out some control panel links $thisTitle = SpecialPage::getTitleFor( 'Watchlist' ); @@ -272,10 +272,14 @@ function wfSpecialWatchlist( $par ) { $linkBits = wfArrayToCGI( array( 'hideOwn' => 1 - (int)$hideOwn ), $nondefaults ); $links[] = $skin->makeKnownLinkObj( $thisTitle, $label, $linkBits ); - $wgOut->addHTML( implode( ' | ', $links ) ); - - # Form for namespace filtering - $form = Xml::openElement( 'form', array( 'method' => 'post', 'action' => $thisTitle->getLocalUrl() ) ); + # Namespace filter and put the whole form together. + $form = Xml::openElement( 'fieldset', array( 'id' => 'mw-watchlist-options' ) ); + $form .= Xml::openElement( 'legend', array( 'id' => 'mw-watchlist-legend' ) ); + $form .= wfMsgExt( 'watchlist-options', array('escape') ); + $form .= Xml::closeElement( 'legend' ); + $form .= $cutofflinks; + $form .= implode( ' | ', $links ); + $form .= Xml::openElement( 'form', array( 'method' => 'post', 'action' => $thisTitle->getLocalUrl() ) ); $form .= '

'; $form .= Xml::label( wfMsg( 'namespace' ), 'namespace' ) . ' '; $form .= Xml::namespaceSelector( $nameSpace, '' ) . ' '; @@ -293,6 +297,7 @@ function wfSpecialWatchlist( $par ) { if( $hideOwn ) $form .= Xml::hidden( 'hideOwn', 1 ); $form .= Xml::closeElement( 'form' ); + $form .= Xml::closeElement( 'fieldset' ); $wgOut->addHtml( $form ); # If there's nothing to show, stop here diff --git a/languages/messages/MessagesEn.php b/languages/messages/MessagesEn.php index f05b876e2a..7b88b8fc18 100644 --- a/languages/messages/MessagesEn.php +++ b/languages/messages/MessagesEn.php @@ -2164,6 +2164,7 @@ Future changes to this page and its associated talk page will be listed there, a 'watchlist-hide-anons' => 'Hide anonymous edits', 'watchlist-show-liu' => 'Show logged-in user edits', 'watchlist-hide-liu' => 'Hide logged-in user edits', +'watchlist-options' => 'Watchlist options', # Displayed when you click the "watch" button and it is in the process of watching 'watching' => 'Watching...', diff --git a/maintenance/language/messages.inc b/maintenance/language/messages.inc index 9619dfa029..d9968775db 100644 --- a/maintenance/language/messages.inc +++ b/maintenance/language/messages.inc @@ -1436,6 +1436,7 @@ $wgMessageStructure = array( 'watchlist-hide-anons', 'watchlist-show-liu', 'watchlist-hide-liu', + 'watchlist-options', ), 'watching' => array( 'watching',