I was wondering how I would be able to script a plugin that would toggle subd surfaces preview if it has a sudb modifier on. It would also be helpful that if the selected object doesn't have a subd modifier in the stack already, it would add one and then toggle the subd view.
Maya allows you to toggle between subd view through the 1 and 3 key and thought this would be really neat to have in Blender but also the addition to add the modifier if it doesn't already have one on. I just don't know how to script and was wondering if anyone has already done this or not.