Skip to content
Snippets Groups Projects
Commit 373d571d authored by chrisgarrity's avatar chrisgarrity
Browse files

refresh blocks after setLocale promise returns

parent 3ed7a4b8
No related branches found
No related tags found
No related merge requests found
......@@ -148,11 +148,12 @@ class Blocks extends React.Component {
setLocale () {
this.workspace.getFlyout().setRecyclingEnabled(false);
this.ScratchBlocks.ScratchMsgs.setLocale(this.props.locale);
this.props.vm.setLocale(this.props.locale, this.props.messages);
this.workspace.updateToolbox(this.props.toolboxXML);
this.props.vm.refreshWorkspace();
this.workspace.getFlyout().setRecyclingEnabled(true);
this.props.vm.setLocale(this.props.locale, this.props.messages)
.then(() => {
this.workspace.updateToolbox(this.props.toolboxXML);
this.props.vm.refreshWorkspace();
this.workspace.getFlyout().setRecyclingEnabled(true);
});
}
updateToolbox () {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment