From 6aab238773f9de3d6a8796f38f92c403b194ae9f Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Thu, 31 Oct 2019 16:11:38 +0100 Subject: [PATCH] Small code improvements --- skins/elastic/ui.js | 70 +++++++++++++++++++++------------------------ 1 file changed, 32 insertions(+), 38 deletions(-) diff --git a/skins/elastic/ui.js b/skins/elastic/ui.js index 7ed7dd418..36da378ce 100644 --- a/skins/elastic/ui.js +++ b/skins/elastic/ui.js @@ -119,7 +119,7 @@ function rcube_elastic_ui() // Intercept jQuery-UI dialogs... $.ui && $.widget('ui.dialog', $.ui.dialog, { open: function() { - // .. to unify min width for iframe'd dialogs + // ... to unify min width for iframe'd dialogs if ($(this.element).is('.iframe')) { this.options.width = Math.max(576, this.options.width); } @@ -152,20 +152,20 @@ function rcube_elastic_ui() } } else if (!is_framed) { - title = $('.boxtitle', layout.content).first().detach().text(); + title = layout.content.find('.boxtitle').first().detach().text(); if (!title) { title = $('h1.voice').first().text(); } if (title) { - $('.header > .header-title', layout.content).text(title); + layout.content.find('.header > .header-title').text(title); } } // Add content frame toolbar in the footer, for content buttons and navigation - if (!is_framed && layout.content.length && !$(layout.content).is('.no-navbar') - && !$(layout.content).children('.frame-content').length + if (!is_framed && layout.content.length && !layout.content.is('.no-navbar') + && !layout.content.children('.frame-content').length ) { env.frame_nav = $('