From 81745502e7346ae3ef5c6d0402a52388825c6db6 Mon Sep 17 00:00:00 2001 From: jmoenig Date: Tue, 8 Jul 2014 13:26:42 +0200 Subject: [PATCH] =?UTF-8?q?show=20username=20in=20=E2=80=98logout=E2=80=99?= =?UTF-8?q?=20entry=20of=20cloud=20menu?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gui.js | 14 ++++++-------- history.txt | 1 + 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/gui.js b/gui.js index 716f93b2..ce8ec394 100644 --- a/gui.js +++ b/gui.js @@ -69,7 +69,7 @@ SpeechBubbleMorph*/ // Global stuff //////////////////////////////////////////////////////// -modules.gui = '2014-Jun-23'; +modules.gui = '2014-July-08'; // Declarations @@ -924,6 +924,8 @@ IDE_Morph.prototype.createSpriteBar = function () { tabColors = this.tabColors, tabBar = new AlignmentMorph('row', -tabCorner * 2), tab, + symbols = ['\u2192', '\u21BB', '\u2194'], + labels = ['don\'t rotate', 'can rotate', 'only face left/right'], myself = this; if (this.spriteBar) { @@ -952,17 +954,13 @@ IDE_Morph.prototype.createSpriteBar = function () { each.refresh(); }); }, - ['\u2192', '\u21BB', '\u2194'][rotationStyle], // label + symbols[rotationStyle], // label function () { // query return myself.currentSprite instanceof SpriteMorph && myself.currentSprite.rotationStyle === rotationStyle; }, null, // environment - localize( - [ - 'don\'t rotate', 'can rotate', 'only face left/right' - ][rotationStyle] - ) + localize(labels[rotationStyle]) ); button.corner = 8; @@ -1947,7 +1945,7 @@ IDE_Morph.prototype.cloudMenu = function () { ); } else { menu.addItem( - 'Logout', + localize('Logout') + ' ' + SnapCloud.username, 'logout' ); menu.addItem( diff --git a/history.txt b/history.txt index c5195165..343a0812 100755 --- a/history.txt +++ b/history.txt @@ -2181,3 +2181,4 @@ ______ ------ * Threads: show error messages for custom blocks (propagating to the script’s top block) * Threads: adjust to Doug Crockford’s latest infuriating nitpickings in JSLint +* GUI: show username in ‘logout’ entry of cloud menu