Rajeev
Rajeev

Reputation: 46899

Declaring buttons in Action script code

How to declare the buttons in the following AS code What is the library that needs to be included

package
{

    public class caml extends Sprite
    {

       public function buttons()
       {
         saveButton.visible = false;
         discardButton.visible = false;

       }
       private function captureImage(e:MouseEvent):void
       {
         capture.visible = false;
         saveButton.visible = true;
         discardButton.visible = true;
       }

    }   

 }

Upvotes: 0

Views: 141

Answers (1)

Patrick
Patrick

Reputation: 15717

If you mean buttons as in the Flash IDE and not the component one, these are SimpleButton

package {
 import flash.display.SimpleButton;
 public class caml extends Sprite {
   public var saveButton:SimpleButton;
   //...
 }
}

Upvotes: 1

Related Questions