trun / flashblocks Goto Github PK
View Code? Open in Web Editor NEWframework for block based programming languages
License: MIT License
framework for block based programming languages
License: MIT License
When dropping a block on an older sibling port that is already connected to a different parent the following error occurs...
ArgumentError: Error #2024: An object cannot be added as a child of itself.
at flash.display::DisplayObjectContainer/addChildAt()
at mx.core::UIComponent/http://www.adobe.com/2006/flex/mx/internal::$addChildAt()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:5094]
at mx.core::Container/addChildAt()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\Container.as:2258]
at mx.core::Container/addChild()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\Container.as:2183]
at com.flashblocks.blocks::CommandBlock/connectOlderSibling()[G:\Projects\flashblocks\src\com\flashblocks\blocks\CommandBlock.as:34]
at com.flashblocks::Page/tryConnection()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:121]
at com.flashblocks::Page/tryConnection()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:140]
at com.flashblocks::Page/tryConnection()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:146]
at com.flashblocks::Page/addBlock()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:50]
at com.flashblocks::BlockDragLayer/onBlockDragComplete()[G:\Projects\flashblocks\src\com\flashblocks\BlockDragLayer.as:135]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks::Workspace/rebroadcastEvent()[G:\Projects\flashblocks\src\com\flashblocks\Workspace.as:267]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks.blocks::SimpleBlock/onMouseUp()[G:\Projects\flashblocks\src\com\flashblocks\blocks\SimpleBlock.as:154]
A simple example...
CONTROL:
FUNC_A
FUNC_B
Drop FUNC_A
such that...
CONTROL:
// pass
FUNC_A
FUNC_B
...and the bottom port of FUNC_A
connects to the older port of FUNC_B
.
Repeat
Repeat
Forward
Drag the forward block up over the two nested repeat blocks, it will glitch hard. No idea what the cause is yet.
ArgumentError: Error #2024: An object cannot be added as a child of itself.
at flash.display::DisplayObjectContainer/addChildAt()
at mx.core::UIComponent/http://www.adobe.com/2006/flex/mx/internal::$addChildAt()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:5094]
at mx.core::Container/addChildAt()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\Container.as:2258]
at mx.core::Container/addChild()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\Container.as:2183]
at com.flashblocks.blocks::CommandBlock/connectAfter()[G:\Projects\flashblocks\src\com\flashblocks\blocks\CommandBlock.as:37]
at com.flashblocks.blocks::CommandBlock/connectAfter()[G:\Projects\flashblocks\src\com\flashblocks\blocks\CommandBlock.as:43]
at com.flashblocks::Page/tryConnection()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:106]
at com.flashblocks::Page/tryConnection()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:132]
at com.flashblocks::Page/tryConnection()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:132]
at com.flashblocks::Page/tryConnection()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:132]
at com.flashblocks::Page/addBlock()[G:\Projects\flashblocks\src\com\flashblocks\Page.as:43]
at com.flashblocks::BlockDragLayer/onBlockDragComplete()[G:\Projects\flashblocks\src\com\flashblocks\BlockDragLayer.as:141]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks::Workspace/rebroadcastEvent()[G:\Projects\flashblocks\src\com\flashblocks\Workspace.as:70]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks.blocks::SimpleBlock/onMouseUp()[G:\Projects\flashblocks\src\com\flashblocks\blocks\SimpleBlock.as:151]
Four command blocks were stacked vertically. When editing the argument of the final block in the stack the above error occurred.
Repro'
Repeat
Forward
Disconnect the Forward
block and place it on the page. Try to reconnect the forward block to the same nested port.
Expected: The Forward
block should reconnect
Actual: The Forward
block does not reconnect
Note that the any other block dragged onto the page can connect to the nested port. This leads me to believe the Forward
block's before connection is not getting properly cleaned up.
The primary purpose of leaving "dirty" connections in place while dragging is to facilitate snapping a block back to its original position if dropped on an invalid location. This same goal can be accomplished in one of two alternate ways.
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at com.flashblocks::BlockDragLayer/onBlockDragComplete()[G:\Projects\flashblocks\src\com\flashblocks\BlockDragLayer.as:150]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks::Workspace/rebroadcastEvent()[G:\Projects\flashblocks\src\com\flashblocks\Workspace.as:70]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks.blocks::SimpleBlock/onMouseUp()[G:\Projects\flashblocks\src\com\flashblocks\blocks\SimpleBlock.as:151]
Repro'
Forward
Forward
Pick up one of the Forward
blocks and drop it on a non-widget (e.g. the TurtleCanvas)
TypeError: Error #1010: A term is undefined and has no properties.
at com.flashblocks.blocks::ControlLogicBlock/onNestedBlockDisconnect()[G:\Projects\flashblocks\src\com\flashblocks\blocks\ControlLogicBlock.as:210]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks.blocks::Block/setDragging()[G:\Projects\flashblocks\src\com\flashblocks\blocks\Block.as:248]
at com.flashblocks::BlockDragLayer/startDragBlock()[G:\Projects\flashblocks\src\com\flashblocks\BlockDragLayer.as:84]
at com.flashblocks::BlockDragLayer/addBlock()[G:\Projects\flashblocks\src\com\flashblocks\BlockDragLayer.as:55]
at com.flashblocks::BlockDragLayer/onBlockDragStart()[G:\Projects\flashblocks\src\com\flashblocks\BlockDragLayer.as:110]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks::Workspace/rebroadcastEvent()[G:\Projects\flashblocks\src\com\flashblocks\Workspace.as:269]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[C:\autobuild\3.5.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9440]
at com.flashblocks.blocks::ControlLogicBlock/onMouseDown()[G:\Projects\flashblocks\src\com\flashblocks\blocks\ControlLogicBlock.as:232]
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.