kopia lustrzana https://github.com/backface/turtlestitch
new "variables" choice in OF reporter's attribute dropdown
rodzic
4c1c1d4d27
commit
575180c9e4
|
@ -18,6 +18,7 @@
|
|||
* new POSITION primitive reporter in the MOTION category
|
||||
* new MOUSE POSITION primitive reporter in the SENSING category
|
||||
* new "position" choice in OF reporter's attribute dropdown, reports a list of XY coordinates
|
||||
* new "variables" choice in OF reporter's attribute dropdown, reports a list of reachable variable names
|
||||
* new "categories" choice in MY reporter's dropdown, reports an ordered list of all category names whose indices match the "category" reported elsewhere
|
||||
* new "label", "type", "scope", "slots", "defaults", "menus" and "editables" choices in the OF BLOCK block-attribute reporter's dropdown
|
||||
* new "set attribute of block" primitive
|
||||
|
@ -67,6 +68,7 @@
|
|||
* gui: added credits for Bambi
|
||||
* gui: added credits for Glen & team
|
||||
* gui: added credits for Meghan
|
||||
* blocks, threads: new "variables" choice in OF reporter's attribute dropdown, reports a list of reachable variable names
|
||||
|
||||
### 2022-08-02
|
||||
* cloud: update
|
||||
|
|
|
@ -16,8 +16,8 @@
|
|||
<script src="src/morphic.js?version=2022-04-26"></script>
|
||||
<script src="src/symbols.js?version=2021-03-03"></script>
|
||||
<script src="src/widgets.js?version=2022-08-01"></script>
|
||||
<script src="src/blocks.js?version=2022-08-01"></script>
|
||||
<script src="src/threads.js?version=2022-08-01"></script>
|
||||
<script src="src/blocks.js?version=2022-08-03"></script>
|
||||
<script src="src/threads.js?version=2022-08-03"></script>
|
||||
<script src="src/objects.js?version=2022-08-01"></script>
|
||||
<script src="src/scenes.js?version=2022-03-03"></script>
|
||||
<script src="src/gui.js?version=2022-08-03"></script>
|
||||
|
|
|
@ -161,7 +161,7 @@ CostumeIconMorph, SoundIconMorph, SVG_Costume, embedMetadataPNG*/
|
|||
|
||||
// Global stuff ////////////////////////////////////////////////////////
|
||||
|
||||
modules.blocks = '2022-August-01';
|
||||
modules.blocks = '2022-August-03';
|
||||
|
||||
var SyntaxElementMorph;
|
||||
var BlockMorph;
|
||||
|
@ -10602,10 +10602,11 @@ InputSlotMorph.prototype.attributesMenu = function (searching) {
|
|||
'bottom' : ['bottom']
|
||||
};
|
||||
}
|
||||
dict['~'] = null;
|
||||
dict.variables = ['variables'];
|
||||
if (obj) {
|
||||
varNames = obj.variables.names();
|
||||
if (varNames.length > 0) {
|
||||
dict['~'] = null;
|
||||
varNames.forEach(name =>
|
||||
dict[name] = name
|
||||
);
|
||||
|
|
|
@ -65,7 +65,7 @@ StagePickerMorph, CustomBlockDefinition*/
|
|||
|
||||
/*jshint esversion: 11, bitwise: false, evil: true*/
|
||||
|
||||
modules.threads = '2022-August-01';
|
||||
modules.threads = '2022-August-03';
|
||||
|
||||
var ThreadManager;
|
||||
var Process;
|
||||
|
@ -5658,12 +5658,14 @@ Process.prototype.reportBasicAttributeOf = function (attribute, name) {
|
|||
if (thisObj) {
|
||||
this.assertAlive(thisObj);
|
||||
stage = thisObj.parentThatIsA(StageMorph);
|
||||
if (stage.name === name) {
|
||||
if (name instanceof Context) {
|
||||
thatObj = name;
|
||||
} else if (stage.name === name) {
|
||||
thatObj = stage;
|
||||
} else {
|
||||
thatObj = this.getOtherObject(name, thisObj, stage);
|
||||
}
|
||||
if (thatObj) {
|
||||
if (isSnapObject(thatObj)) {
|
||||
this.assertAlive(thatObj);
|
||||
if (attribute instanceof BlockMorph) { // a "wish"
|
||||
return this.reportContextFor(
|
||||
|
@ -5726,6 +5728,12 @@ Process.prototype.reportBasicAttributeOf = function (attribute, name) {
|
|||
return thatObj.yBottom();
|
||||
}
|
||||
}
|
||||
if (this.inputOption(attribute) === 'variables') {
|
||||
return new List((thatObj instanceof Context ?
|
||||
thatObj.outerContext
|
||||
: thatObj).variables.allNames()
|
||||
);
|
||||
}
|
||||
}
|
||||
return '';
|
||||
};
|
||||
|
|
Ładowanie…
Reference in New Issue