google / blockly-android

Blockly for Android
Apache License 2.0
673 stars 209 forks source link

Fill in block background to end of line #583

Closed RoboErikG closed 7 years ago

RoboErikG commented 7 years ago

Fixes #504. For inline inputs if the inputs didn't go to the end of the line there would be an emtpy rectangle after them. This checks if there's empty space after the last input on a line and fills it in.

Also simplifies the check if a location is within a block.


This change is Reviewable

RoboErikG commented 7 years ago

Review status: 0 of 2 files reviewed at latest revision, 1 unresolved discussion.


blocklylib-vertical/src/main/java/com/google/blockly/android/ui/vertical/BlockView.java, line 274 at r1 (raw file):

Previously, AnmAtAnm (Andrew n marshall) wrote…
Per offline, while definitely an improvement (good enough to submit), it would be great to get the outer block border included in the hit test.

Would be nice, but I'm not sure how we'll get it. I tried iterating through the patches too but the statement patch includes a fair amount of open space.


Comments from Reviewable