Making default name for broadcast messages amenable to translation.

This commit is contained in:
Karishma Chadha 2017-11-20 12:05:55 -05:00
parent c1044047f0
commit 2d0d9dba0b
2 changed files with 7 additions and 4 deletions

View file

@ -80,7 +80,7 @@ Blockly.Blocks['event_whenbroadcastreceived'] = {
"type": "field_variable",
"name": "BROADCAST_OPTION",
"variableTypes": ["broadcast_msg"],
"variable": "message1"
"variable": Blockly.Msg.DEFAULT_BROADCAST_MESSAGE_NAME
}
],
"category": Blockly.Categories.event,
@ -153,7 +153,7 @@ Blockly.Blocks['event_broadcast_menu'] = {
"type": "field_variable",
"name": "BROADCAST_OPTION",
"variableTypes":["broadcast_msg"],
"variable":"message1"
"variable": Blockly.Msg.DEFAULT_BROADCAST_MESSAGE_NAME
}
],
"colour": Blockly.Colours.event.secondary,
@ -178,7 +178,7 @@ Blockly.Blocks['event_broadcast'] = {
"type": "field_variable",
"name": "BROADCAST_OPTION",
"variableTypes": ["broadcast_msg"],
"variable": "message1"
"variable": Blockly.Msg.DEFAULT_BROADCAST_MESSAGE_NAME
}
],
"category": Blockly.Categories.event,
@ -200,7 +200,7 @@ Blockly.Blocks['event_broadcastandwait'] = {
"type": "field_variable",
"name": "BROADCAST_OPTION",
"variableTypes": ["broadcast_msg"],
"variable":"message1"
"variable": Blockly.Msg.DEFAULT_BROADCAST_MESSAGE_NAME
}
],
"category": Blockly.Categories.event,

View file

@ -143,6 +143,9 @@ Blockly.Msg.NEW_LIST = 'Create list...';
// Broadcast Message creation
/// dropdown choice - Create a new message.
Blockly.Msg.NEW_BROADCAST_MESSAGE = 'New message...';
/// default broadcast message name
/// (default option in broadcast message dropdown menus)
Blockly.Msg.DEFAULT_BROADCAST_MESSAGE_NAME = 'message1';
// Variable deletion.
/// confirm - Ask the user to confirm their deletion of multiple uses of a variable.