Permalink
Browse files

Make buttons look better.

  • Loading branch information...
1 parent 379bcef commit 24d85aef1a5187871cda6a09559a849b1347586a @mythmon mythmon committed May 15, 2012
View
9 web/css/board.css
@@ -40,6 +40,8 @@
margin-right: 5px;
height: 20px;
cursor: pointer;
+ min-width: 75px;
+ text-align: center;
}
.button:hover {
@@ -56,12 +58,17 @@
h3 { margin: 0px; }
/* ICONS */
-.icon-resistor, .icon-wire, .icon-arrow, .icon-node {
+.icon-resistor, .icon-wire, .icon-arrow, .icon-node, .icon-undo, .icon-redo,
+.icon-delete {
background-repeat: no-repeat;
padding-left: 29px;
background-position: 3px 3px;
+ min-width: 49px;
}
.icon-resistor { background-image: url('/img/icons/resistor.png'); }
.icon-wire { background-image: url('/img/icons/wire.png'); }
.icon-arrow { background-image: url('/img/icons/arrow.png'); }
.icon-node { background-image: url('/img/icons/node.png'); }
+.icon-undo { background-image: url('/img/icons/undo.png'); }
+.icon-redo { background-image: url('/img/icons/redo.png'); }
+.icon-delete { background-image: url('/img/icons/delete.png'); }
View
BIN web/img/icons/delete.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN web/img/icons/redo.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN web/img/icons/undo.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
6 web/js/board.js
@@ -1164,7 +1164,7 @@ var Undo = Class.extend({
init: function(self, board) {
self.board = board;
- self.elem = $('<div class="button" id="tool_undo">Undo</div>')
+ self.elem = $('<div class="button icon-undo" id="tool_undo">Undo</div>')
.appendTo('#actions')
.bind('click', function() {
console.log('Undoing.');
@@ -1179,7 +1179,7 @@ var Redo = Class.extend({
init: function(self, board) {
self.board = board;
- self.elem = $('<div class="button">Redo</div>')
+ self.elem = $('<div class="button icon-redo">Redo</div>')
.appendTo('#actions')
.bind('click', function() {
console.log('Redoing.');
@@ -1194,7 +1194,7 @@ var Delete = Class.extend({
init: function(self, board) {
self.board = board;
- self.elem = $('<div class="button" id="delete_button">Delete</div>')
+ self.elem = $('<div class="button icon-delete">Delete</div>')
.appendTo('#actions')
.bind('click', function() {
var selected = self.board.selected();

0 comments on commit 24d85ae

Please sign in to comment.