Commit Graph

9 Commits

Author SHA1 Message Date
Neil Fraser
52b6ce18a5 Fix unit tests 2019-07-08 13:29:43 -07:00
Jim Jiang
1b10d134a5 Add Block.setEnabled (#2386)
* Implement Block.setEnabled()

From issue #1593. This commit:
- add setEnabled
- deprecate setDisabled

* Update setDisabled calls to setEnabled

Add setEnabled and deprecate setDisabled in
- core/block_svg

Update calls in
- blocks/loops
- blocks/procedures
- core/block_events
- core/events
- core/flyout_base
- core/xml
- tests/workplace_svg/procedure_svg_test

* Implement changes from comments from RoboErikG

- Implement isEnabled()
- Make this.disabled @private
- Make setDisabled(disabled) call setEnabled(!disabled)
- Update setEnabled to use isEnabled()

* Utilize isEnabled() and fix typos

Fix missing parentheses
Implement isEnabled() more widely
Fix lint and parentheses errors

* Change prevDisabledState to prevEnabledState
2019-04-23 08:49:07 -07:00
Nadya Febiana Djojosantoso
d822efa322 Add math_atan2 block to demos and playgrounds 2018-10-11 14:56:13 -07:00
RoboErikG
9eacd7d3b9 Disable/enable function calls along with their definitions (#2019)
Fixes #1344

Extends the event listener on procedure caller blocks to also check
for their definition being enabled/disabled and update their own
state in response.
2018-08-23 11:18:29 -07:00
RoboErikG
22fc0f8af9 Add test for replacing a rendered shadow block (#1981)
PR #1970 created a bug that only occurred when replacing a rendered
shadow block. Add a test for this case to prevent breaking it again.
2018-08-14 09:52:02 -07:00
RoboErikG
61803167d8 Add test for deleting a rendered block with a comment (#1984)
Disabled for now as it fails due to #1960.
2018-07-23 10:56:37 -07:00
RoboErikG
c815608fdf Fix failing svg canvas test (#1977)
Partial fix for #1976. This fixes the broken test by initializing the
svg for blocks when they're created.
2018-07-17 09:35:53 -07:00
Andrew n marshall
6e1ffe09c2 Adding Blockly.Xml.appendDomToWorkspace() (#962)
This is a copy (with additional comments) of PR #822 (and also #961) by @qnoirhomme with unrelated files removed. See #822 for full review.
2017-03-03 08:40:00 -08:00
Rachel Fenichel
1881b0c3fa Add skeleton for tests on rendered workspaces 2017-02-02 16:08:03 -08:00