Commit graph

1727 commits

Author SHA1 Message Date
Paul Kaplan
db865f24f4 Remove unused variable category code.
It had been moved to the data_category.js file. It is dead code now.
2017-10-31 09:34:19 -04:00
Paul Kaplan
d735d33351 Change "change by" default value to 1 instead of 0. 2017-10-31 09:30:35 -04:00
Paul Kaplan
2cf42d13db Make XML creation for data category more explicit.
But no changes to defaults.
2017-10-31 09:29:58 -04:00
Rachel Fenichel
a02d69e09b Make the 'ok' button apply a mutation in the custom procedure playground 2017-10-27 11:12:46 -07:00
picklesrus
b48b0dc67e Add the new clearWorkspaceAndLoadFromXml to the set of globals so the compiler does not rename it. This should have been part of #1178 (#1184) 2017-10-26 11:16:45 -07:00
Paul Kaplan
e04cf81727 Merge pull request #1182 from paulkaplan/fix-flyout-var-ids
Re-fix the flyout variable block IDs
2017-10-25 14:43:53 -04:00
Paul Kaplan
4dc0e845b1 Add id to comment showing what it looks like 2017-10-25 14:36:55 -04:00
Paul Kaplan
9d03bf1511 Re-fix the flyout variable block IDs 2017-10-25 12:43:08 -04:00
Rachel Fenichel
6a0d58bb5d Merge pull request #1179 from rachel-fenichel/bugfix/no_toolbox_ws
Don't parse the default toolbox if it doesn't exist
2017-10-25 09:13:16 -07:00
Rachel Fenichel
ce31ae9743 Don't parse the default toolbox if it doesn't exist 2017-10-24 18:03:17 -07:00
picklesrus
a54957c637 Add an xml utility to clear the workspace and then load xml into the dom. In it, use a new toolbox refresh mechanism that allows for batch updates. It mirrors the setResizesEnabled mechanism for managing batch updates to the workspace. 2017-10-24 14:33:53 -07:00
picklesrus
2996c86c53 Do not refresh the toolbox when a new variable is created on the work… (#1166)
* Do not refresh the toolbox when a new variable is created on the workspace but it already exists in the variable map.  This gets rid of some calls to Toolbox.refreshSelection. e.g. when you drag a variable block out of the toolbox, we were refreshing the toolbox.  It will also help with xml loading for workspaces using multiple of the same variable reporter.  More needs to be done to solve #879, but this helps a little.

* Fix typo
2017-10-24 12:40:22 -07:00
Paul Kaplan
334baaf175 Use "Color" instead of "Hue" as the slider color input. 2017-10-23 16:40:30 -04:00
Paul Kaplan
97426e17b2 Merge pull request #1168 from picklesrus/develop-revert-bulk-update
Revert #1122 and changes made on top of it.
2017-10-23 10:24:44 -04:00
Paul Kaplan
7fc1a4894d Fix trailing spaces. 2017-10-23 10:09:05 -04:00
picklesrus
13e5c30e26 Revert #1122 and changes made on top of it. See discusson on #748 and #1145. We will fix this a different way next week 2017-10-20 17:53:14 -07:00
Rachel Fenichel
3d44202834 Add tests for field serializability. 2017-10-20 15:15:00 -07:00
Rachel Fenichel
0ea49318d3 rename field_label_editable to field_label_serializable 2017-10-20 14:00:09 -07:00
Rachel Fenichel
cb058a69af Add a serializable attribute to field, distinct from EDITABLE 2017-10-20 13:58:20 -07:00
Paul Kaplan
8263afcba5 Revert "Implement Blockly.Events.filter in linear time (#1205)"
This reverts commit 910284856e.
2017-10-20 15:06:48 -04:00
Rachel Fenichel
b4b721df66 Merge pull request #1152 from rachel-fenichel/feature/delete_procedure
Feature/delete procedure
2017-10-20 08:32:44 -07:00
Rachel Fenichel
63ab0baf3b Merge pull request #1158 from rachel-fenichel/bugfix/1127
Hack to fix 1127 while we consider strict connection types
2017-10-20 08:31:43 -07:00
Paul Kaplan
2573eef256 Merge pull request #1157 from paulkaplan/merge-10-19
Merge from blockly/develop on 10/19
2017-10-19 19:07:08 -04:00
Rachel Fenichel
5e3073c441 Hack to fix 1127 while we consider strict connection types 2017-10-19 16:06:12 -07:00
Paul Kaplan
8f5156c72c Fix lost newline 2017-10-19 17:10:42 -04:00
Neil Fraser
d906095698 Style improvements. No functional changes. (#1367) 2017-10-19 17:08:17 -04:00
Nick Allred
86a7b939cb Subtract metrics.contentTop from metrics.viewTop so that the flyout does not begin to scroll down once the delta is smaller than the value of metrics.contentTop (#1309) 2017-10-19 16:57:54 -04:00
Rachel Fenichel
5e386d5bd0 Fix iOS toolbox flashing on tap (#1351) 2017-10-19 16:57:47 -04:00
Rachel Fenichel
e802fb921b Unify code for positioning the widget div (#1334)
* New widget div functions, used in context menu code

* Make all widget div positioning functions use the same argument order

* Use new widget div functions for fields

* share code for measuring menu size

* Get rid of positionMenu

* Update copyright date

* Rebuild blockly_uncompressed because there's a new require in town
2017-10-19 14:58:41 -04:00
Rachel Fenichel
6868b9cccb Code cleanup: widget creation (#1332) 2017-10-19 14:47:32 -04:00
Sam El-Husseini
c55824d619 Avoid IE and Edge re-rendering (#1326)
* Fix wrong width of field_dropdown with an image on Edge / IE

* Avoid re-rendering on IE and Edge by using getBBox().width to compute the text width on those browsers
2017-10-19 14:43:43 -04:00
Rachel Fenichel
c2e7f6dfe8 Make dropdowns update correctly when you switch between images. (#1321) 2017-10-19 14:32:12 -04:00
Rachel Fenichel
971c0c8316 Allow the toolbox to scroll (#1319)
* Allow the toolbox to scroll

* Switch from onMouseDown to onClick_ for toolbox category taps and clicks.
2017-10-19 14:13:34 -04:00
Neil Fraser
75f52db086 Strip licences from compiled code. (#1318) 2017-10-19 14:04:45 -04:00
Sam El-Husseini
9ce71d1099 Fix flyout labels causing flyout scrolling issues (#1301) 2017-10-19 13:04:21 -04:00
Rachel Fenichel
b033c8d3ab Create WorkspaceViewport class (#1291)
* Create WorkspaceViewport class

* Update comments

* Move workspace viewport functions back to the workspace for now

* whitespace
2017-10-19 12:57:28 -04:00
Rachel Fenichel
504c458003 Add annotations for units to scrollbar.js (#1290)
* Add annotations for units to scrollbar.js

* Update comments
2017-10-19 12:38:37 -04:00
Rachel Fenichel
6fb59ccc78 Decompose the showEditor_ function in FieldTextInput (#1285)
* Explicit annotations

* Decompose the showEditor_ function in FieldTextInput

* Remove extra newline
2017-10-19 12:35:11 -04:00
Rachel Fenichel
e38411c07f Clean up code in FieldTextInput (#1284)
* Clean up code in FieldTextInput

* Explicit annotations

* Remove extra newline
2017-10-19 12:29:10 -04:00
Evan W. Patton
910284856e Implement Blockly.Events.filter in linear time (#1205)
* Implement Blockly.Events.filter in linear time

For large App Inventor projects (order 1k+ blocks, 100+ top-level
blocks), the O(n^2) behavior of Blockly.Event.filter was causing
performance issues when rearranging blocks or pasting from the
backpack. This commit provides a linear merge implementation using a
key that uniquely identifies a block so that multiple events targeting
the same block are merged. This change benefits from O(1) amortized
lookup using an object as a key-value store.

* Add event filter unit tests and fix logic bugs

* Update Blockly.Events.filter unit tests
2017-10-19 12:03:51 -04:00
Rachel Fenichel
5ec9195ff1 Bring the most recently edited stack to the front at the end of a drag. (#1283) 2017-10-19 12:03:20 -04:00
Rachel Fenichel
eed4e33f84 Escape variable names correctly when serializing to XML (#1279) 2017-10-19 12:02:42 -04:00
picklesrus
0c09d60ff7 Fix #1275 by adding a more specific rule for overflow:visible on the … (#1280)
* Fix #1275 by adding a more specific rule for overflow:visible on the drag surface svg.  This wins out over a common bootstrap rule that says: svg:not(:root) {overflow:hidden} and helps avoid a difficult problem for Blockly users to diagnose.

* Update css.js
2017-10-19 11:59:21 -04:00
Rachel Fenichel
92e6d339f4 Code cleanup in BlockSvg.prototype.tab (#1277) 2017-10-19 11:56:44 -04:00
RoboErikG
348aba771e Missed one use of string instead of .property in extensions.js (#1262) 2017-10-19 11:53:00 -04:00
RoboErikG
88e404732d Update extensions.js to be compatible with ADVANCED_OPTIMIZATIONS (#1253)
* Update extensions.js to be compatible with ADVANCED_OPTIMIZATIONS

We were using strings to check for the existence of properties on
a mutator, which breaks if those properties were renamed by the
closure compiler. This updates all of the uses to direct function
references so that anyone building with advanced optimizations turned
on will get the correct method references in their mutators.

fixes #1251

* Update to extensions.js for advanced optimizations

Some minor updates to making extensions.js work with advanced
optimizations.

* use === undefined instead of typeof == 'undefined'
2017-10-19 11:52:50 -04:00
marisaleung
6a9617c77d Fix type tags and todo placement. 2017-10-19 11:51:30 -04:00
Neil Fraser
a119cca83b Compatibility for Closure Compiler. (#1240) 2017-10-19 11:47:04 -04:00
Rachel Fenichel
1796a85bd8 Move connection to the correct location 2017-10-18 17:24:02 -07:00
Rachel Fenichel
b64beeb883 Add tests 2017-10-18 17:15:01 -07:00