summaryrefslogtreecommitdiff
path: root/blocks.js
diff options
context:
space:
mode:
authorMichael Ball <cycomachead@gmail.com>2014-02-04 11:59:45 -0800
committerMichael Ball <cycomachead@gmail.com>2014-02-04 11:59:45 -0800
commit817f4c5420e5d55409c88386c478f14e4735a627 (patch)
tree29af845c58934508a0ea842786c5838e8deb4519 /blocks.js
parent9aa3921dd04ee8b6fedec0116f9e3f5503e4043b (diff)
parent8b5fa2ff9bd81ad9227b2593f9ccd6fdb8d32444 (diff)
downloadsnap-yow-817f4c5420e5d55409c88386c478f14e4735a627.tar.gz
snap-yow-817f4c5420e5d55409c88386c478f14e4735a627.zip
resolve merge conflicts; date problems only
Diffstat (limited to 'blocks.js')
-rw-r--r--blocks.js41
1 files changed, 38 insertions, 3 deletions
diff --git a/blocks.js b/blocks.js
index c975e16..1cfd2c2 100644
--- a/blocks.js
+++ b/blocks.js
@@ -9,7 +9,7 @@
written by Jens Mönig
jens@moenig.org
- Copyright (C) 2013 by Jens Mönig
+ Copyright (C) 2014 by Jens Mönig
This file is part of Snap!.
@@ -155,7 +155,8 @@ DialogBoxMorph, BlockInputFragmentMorph, PrototypeHatBlockMorph, Costume*/
// Global stuff ////////////////////////////////////////////////////////
-modules.blocks = '2013-December-27';
+modules.blocks = '2014-February-04';
+
var SyntaxElementMorph;
var BlockMorph;
@@ -1014,7 +1015,6 @@ SyntaxElementMorph.prototype.labelPart = function (spec) {
'attributesMenu',
true
);
- part.isStatic = true;
break;
case '%fun':
part = new InputSlotMorph(
@@ -1056,6 +1056,33 @@ SyntaxElementMorph.prototype.labelPart = function (spec) {
);
part.setContents(['encode URI']);
break;
+ case '%stopChoices':
+ part = new InputSlotMorph(
+ null,
+ false,
+ {
+ 'all' : ['all'],
+ 'this script' : ['this script'],
+ 'this block' : ['this block']
+ },
+ true
+ );
+ part.setContents(['all']);
+ part.isStatic = true;
+ break;
+ case '%stopOthersChoices':
+ part = new InputSlotMorph(
+ null,
+ false,
+ {
+ 'all but this script' : ['all but this script'],
+ 'other scripts in sprite' : ['other scripts in sprite']
+ },
+ true
+ );
+ part.setContents(['all but this script']);
+ part.isStatic = true;
+ break;
case '%typ':
part = new InputSlotMorph(
null,
@@ -3284,6 +3311,7 @@ CommandBlockMorph.prototype.snap = function () {
CommandBlockMorph.prototype.isStop = function () {
return ([
+ 'doStopThis',
'doStop',
'doStopBlock',
'doStopAll',
@@ -6319,6 +6347,8 @@ InputSlotMorph.prototype.dropDownMenu = function () {
if (Object.prototype.hasOwnProperty.call(choices, key)) {
if (key[0] === '~') {
menu.addLine();
+ // } else if (key.indexOf('§_def') === 0) {
+ // menu.addItem(choices[key].blockInstance(), choices[key]);
} else {
menu.addItem(key, choices[key]);
}
@@ -6535,6 +6565,11 @@ InputSlotMorph.prototype.attributesMenu = function () {
dict[name] = name;
});
}
+ /*
+ obj.customBlocks.forEach(function (def, i) {
+ dict['§_def' + i] = def
+ });
+ */
return dict;
};