diff --git a/www/code/inner.js b/www/code/inner.js
index 53ebf08ef..91ea32a85 100644
--- a/www/code/inner.js
+++ b/www/code/inner.js
@@ -99,9 +99,11 @@ define([
});
var onBlur = function (e) {
if (e.relatedTarget) {
- if ($(e.relatedTarget).is('.cp-toolbar-drawer-button')) { return; }
- if ($(e.relatedTarget).parents('.cp-toolbar-drawer-content').length) {
- $(e.relatedTarget).blur(onBlur);
+ var $relatedTarget = $(e.relatedTarget);
+
+ if ($relatedTarget.is('.cp-toolbar-drawer-button')) { return; }
+ if ($relatedTarget.parents('.cp-toolbar-drawer-content').length) {
+ $relatedTarget.blur(onBlur);
return;
}
}
@@ -416,7 +418,11 @@ define([
var $content = $('#cp-app-code-preview-content');
mkPrintButton(framework, $content, $print);
-
+ // XXX don't display the help menu in embed mode?
+ // metadataMgr.getPrivateData().isEmbed
+ // do the same in all other apps
+ // pad, code, oo, slide, poll, whiteboard, kanban
+ // OR do it in a more generic way...
mkHelpMenu(framework);
var evModeChange = Util.mkEvent();
diff --git a/www/common/notifications.js b/www/common/notifications.js
index 5b7767e86..127c0621a 100644
--- a/www/common/notifications.js
+++ b/www/common/notifications.js
@@ -365,7 +365,7 @@ define([
}
};
- Messages.todo_move = "Your todo list has been moved to the pad {0}, as the Todo app is now deprecated.";
+ Messages.todo_move = "Your todo list has been moved to the pad {0}, as the Todo app is now deprecated."; // XXX
handlers['MOVE_TODO'] = function(common, data) {
var content = data.content;
var msg = content.msg;
diff --git a/www/common/sframe-common-codemirror.js b/www/common/sframe-common-codemirror.js
index 1ddedcebd..9efd30bce 100644
--- a/www/common/sframe-common-codemirror.js
+++ b/www/common/sframe-common-codemirror.js
@@ -359,7 +359,7 @@ define([
content: l.name // Pretty name of the language value
});
});
- Messages.code_editorTheme = "Editor theme";
+ Messages.code_editorTheme = "Editor theme"; // XXX
var dropdownConfig = {
text: Messages.code_editorTheme, // Button initial text
options: options, // Entries displayed in the menu
@@ -370,6 +370,7 @@ define([
};
var $block = exp.$theme = UIElements.createDropdown(dropdownConfig);
$block.find('button').attr('title', Messages.themeButtonTitle).click(function () {
+ // XXX copy-pasted code from configureLanguage. We can refactor this.
var state = $block.find('.cp-dropdown-content').is(':visible');
var $c = $block.closest('.cp-toolbar-drawer-content');
$c.removeClass('cp-dropdown-visible');
diff --git a/www/common/toolbar.js b/www/common/toolbar.js
index fa0e27346..c20453d93 100644
--- a/www/common/toolbar.js
+++ b/www/common/toolbar.js
@@ -92,6 +92,7 @@ MessengerUI, Messages) {
Messages.toolbar_file = "File"; // XXX
if (!config.hideDrawer) {
+ // XXX a lot of this logic is duplicated (code, slide, here)
var $drawer = $(h('button.' + FILE_CLS, [
h('i.fa.fa-file-o'),
h('span.cp-button-name', Messages.toolbar_file)
diff --git a/www/slide/inner.js b/www/slide/inner.js
index e70503325..90c5b4842 100644
--- a/www/slide/inner.js
+++ b/www/slide/inner.js
@@ -100,6 +100,7 @@ define([
});
};
+ // XXX this function is a duplicate of /code/
var mkThemeButton = function (framework) {
Messages.toolbar_theme = "Theme"; // XXX
var $theme = $(h('button.cp-toolbar-appmenu', [