From 0aecfad854234712c3ded0165e15b9a1fbb227d6 Mon Sep 17 00:00:00 2001 From: Caleb James DeLisle Date: Thu, 5 Oct 2017 16:12:49 +0300 Subject: [PATCH] Occasionally the language selector only says "Mode" rather than the language --- www/common/sframe-common-codemirror.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/www/common/sframe-common-codemirror.js b/www/common/sframe-common-codemirror.js index 4fd5d0251..9462a1fd4 100644 --- a/www/common/sframe-common-codemirror.js +++ b/www/common/sframe-common-codemirror.js @@ -152,7 +152,7 @@ define([ }); }); var dropdownConfig = { - text: 'Mode', // Button initial text + text: Messages.languageButton, // Button initial text options: options, // Entries displayed in the menu left: true, // Open to the left of the button isSelect: true, @@ -166,6 +166,7 @@ define([ }); if ($drawer) { $drawer.append($block); } + if (exp.highlightMode) { exp.setMode(exp.highlightMode); } if (cb) { cb(); } }; @@ -212,8 +213,6 @@ define([ }; exp.getContentExtension = function () { - console.log(Modes.extensionOf(exp.highlightMode)); - console.log(exp.highlightMode); return (Modes.extensionOf(exp.highlightMode) || '.txt').slice(1); }; exp.fileExporter = function () {