From a6a21d21aecfe66c70aa196de2bfb489509d610f Mon Sep 17 00:00:00 2001 From: Mark Salsbery Date: Fri, 6 Dec 2013 11:22:51 -0800 Subject: [PATCH] Button Image Alignment Fix (#272, #30) Changed button element from button to div for consistent rendering across browsers. --- src/button.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/button.js b/src/button.js index abadaff4..36d1a72d 100644 --- a/src/button.js +++ b/src/button.js @@ -120,7 +120,7 @@ $.Button = function( options ) { * @member {Element} element * @memberof OpenSeadragon.Button# */ - this.element = options.element || $.makeNeutralElement( "button" ); + this.element = options.element || $.makeNeutralElement( "div" ); //if the user has specified the element to bind the control to explicitly //then do not add the default control images @@ -183,6 +183,7 @@ $.Button = function( options ) { // Whether this button should fade after user stops interacting with the viewport. this.shouldFade = false; + this.element.style.cursor = "pointer"; this.element.style.display = "inline-block"; this.element.style.position = "relative"; this.element.title = this.tooltip;