TypeError: Error #2007: Parameter child must be non-null. at flash.display::DisplayObjectContainer/addChild()
问题 Created a button, now tried to add it to the screen and im getting this error. The code for the button is - private function submitButton():void { submit_button=new SimpleButton(); submit_button.x=200; submit_button.y=200; submit_button.upState=buttonShape(); submit_button.overState=buttonShape(); submit_button.downState=buttonShape(); } private function buttonShape() { var rectangle:Shape = new Shape; // initializing the variable named rectangle rectangle.graphics.beginFill(0x8C2B44); //