From f6da60cfab2ef394e03e54c8e13f5bd26ebd9f21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20Laxstr=C3=B6m?= Date: Mon, 15 Aug 2016 10:54:42 +0200 Subject: [PATCH] DisplaySettings: disallow focus on tabgroup buttons Focus state looks bad in this context. Change-Id: I3bc1cd63123711ded0652910ef4fa62f19c3bd12 --- resources/js/ext.uls.displaysettings.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/resources/js/ext.uls.displaysettings.js b/resources/js/ext.uls.displaysettings.js index 1940084e..18c2e868 100644 --- a/resources/js/ext.uls.displaysettings.js +++ b/resources/js/ext.uls.displaysettings.js @@ -612,7 +612,9 @@ displaySettings.$parent.position(); $tabButtons.removeClass( 'mw-ui-pressed' ); $button.addClass( 'mw-ui-pressed' ); - + } ).on( 'mousedown', function ( event ) { + // Avoid taking focus, to avoid bad looking focus styles + event.preventDefault(); } ); },