mirror of
https://github.com/google/blockly.git
synced 2025-12-15 13:50:08 +01:00
fix: properly pass the block to the icon constructor in blockfactory blocks (#7202)
This commit is contained in:
@@ -336,8 +336,8 @@ Blockly.Blocks['field_dropdown'] = {
|
||||
this.updateShape_();
|
||||
this.setPreviousStatement(true, 'Field');
|
||||
this.setNextStatement(true, 'Field');
|
||||
this.setMutator(new Blockly.icons.MutatorIcon(['field_dropdown_option_text',
|
||||
'field_dropdown_option_image']));
|
||||
this.setMutator(new Blockly.icons.MutatorIcon(
|
||||
['field_dropdown_option_text', 'field_dropdown_option_image'], this));
|
||||
this.setColour(160);
|
||||
this.setTooltip('Dropdown menu with a list of options.');
|
||||
this.setHelpUrl('https://www.youtube.com/watch?v=s2_xaEvcVI0#t=386');
|
||||
@@ -611,7 +611,7 @@ Blockly.Blocks['type_group'] = {
|
||||
this.typeCount_ = 2;
|
||||
this.updateShape_();
|
||||
this.setOutput(true, 'Type');
|
||||
this.setMutator(new Blockly.icons.MutatorIcon(['type_group_item']));
|
||||
this.setMutator(new Blockly.icons.MutatorIcon(['type_group_item'], this));
|
||||
this.setColour(230);
|
||||
this.setTooltip('Allows more than one type to be accepted.');
|
||||
this.setHelpUrl('https://www.youtube.com/watch?v=s2_xaEvcVI0#t=677');
|
||||
|
||||
Reference in New Issue
Block a user