Detect dynamically Sugar/Sugarizer

It's better to detect Sugar/Sugarizer dynamically so you don't have to change your code.

All other things works well for me. Hope it will be the case for you too.

Regarding refresh issue, here the process to reproduce it:
- Start a new TurtleJS instance from Sugarizer menu
- Create blocks: "Repeat 4" with "Left 90 Forward 100" include inside
- Close the activity
- Reopen it: the blocks are displayed but the "Repeat" block has not the right size (don't cover the whole Left+Forward)