Skip to content

Commit

Permalink
Homepage|Master Server: Use a padlock icon for a closed server
Browse files Browse the repository at this point in the history
  • Loading branch information
danij-deng committed Feb 29, 2012
1 parent 300da8f commit e6e5ba3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion web/plugins/masterbrowser/masterbrowser.php
Expand Up @@ -96,8 +96,8 @@ private function generateServerBadgeHtml(&$info)
'</div>'.
'<span class="name">'. htmlspecialchars($info['name']) .'</span>'.
'<div class="server-metadata">'.
'<span class="open"><label title="'. htmlspecialchars($openStatusLabel) .'">'. htmlspecialchars($info['open']? 'Open' : 'Closed') .'</label></span>'.
'<span class="address"><label title="'. htmlspecialchars($addressLabel) .'">'. htmlspecialchars($info['at']) .'<span class="port">'. htmlspecialchars($info['port']) .'</span></label></span>'.
'<label title="'. htmlspecialchars($openStatusLabel) .'"><div class="'. ($info['open']? 'lock-off' : 'lock-on') .'"></div></label>'.
'</div>'.
'<div class="game-metadata">'.
'Setup: <span class="game-setup">'. htmlspecialchars($setupStr) .'</span>'.
Expand Down
14 changes: 12 additions & 2 deletions web/style.css
Expand Up @@ -994,8 +994,18 @@ span.port {
float: right;
}

.server_badge .address {
padding-left: .8em;
div.lock-on, div.lock-off {
background-image: url("/images/lock.png");
background-size: 24px 12px;
display: inline-block;
width: 12px;
height: 12px;
position: relative;
top: 2px;
}

div.lock-on {
background-position-x: 12px;
}

/*------------------ Screens Page ------------------*/
Expand Down

0 comments on commit e6e5ba3

Please sign in to comment.