How can I set active recursively in the editor? Or do I really have to click all those checkboxes?

I just upgraded Unity to 4.1, and the .active .activeInHierarchy / SetActive shenanigans have hosed my custom GUI elements.

SetActive( true) is supposed to work recursively, but it doesn’t, and I found out this is because it only works if all the child objects are active before the game starts. And the active checkbox in the inspector no longer pops up a dialog asking if I want to activate all the children or just the object itself.
Problem is just about everything in my scene starts out inactive, and there is a lot of it.

Come on, Unity, are you seriously going to force me to me to dig through my whole hierarchy and click every single disclosure triangle and then select every single object in my scene and click its active checkbox?

Here’s a custom Editor script that will toggle the selected object’s active state.

public static class SetActiveRecursively
{
	[MenuItem("GameObject/Set Active Recursively")]
	public static void ToggleActive ()
	{
		if (Selection.activeTransform == null)
			return;
		
		ToggleActiveRecursively(Selection.activeTransform, !Selection.activeGameObject.activeSelf);
	}
	
	static void ToggleActiveRecursively (Transform trans, bool active)
	{
		trans.gameObject.SetActive(active);
		foreach (Transform child in trans)
			ToggleActiveRecursively(child, active);
	}
}