general case adding when_run block

We want a top level block similar to when_run in calc, but it will look different

I general cased and renamed the insertWhenRun function to do this.

I also changed our config option to be a block type instead of a boolean.

This is what it looks like
![image](https://cloud.githubusercontent.com/assets/1767466/4868148/ba374eaa-613c-11e4-8da1-a5981dcda203.png)

yeah, any block that starts with functional_ is going to get a functional_input instead of a next. The place we could get into trouble is if our top level block is of type functional_* but does not have an input named ARG1.