Danh mục

Components: A Scripting Primer

Số trang: 3      Loại file: pdf      Dung lượng: 32.77 KB      Lượt xem: 9      Lượt tải: 0    
Thư viện của tui

Phí tải xuống: 4,000 VND Tải xuống file đầy đủ (3 trang) 0
Xem trước 2 trang đầu tiên của tài liệu này:

Thông tin tài liệu:

Các thành phần: Một Scripting Primer Bởi vì trọng tâm của cuốn sách này là ActionScript, thảo luận của chúng tôi trong bài học này chủ yếu tập trung vào làm thế nào để làm việc với và sử dụng các thành phần Flash từ một quan điểm scripting. Để có cái nhìn toàn diện hơn của các thành phần, tham khảo tài liệu mà đi kèm với Flash.
Nội dung trích xuất từ tài liệu:
Components: A Scripting Primer < Day Day Up >Components: A Scripting PrimerBecause the focus of this book is ActionScript, our discussion in this lesson largelycenters on how to work with and use Flash components from a scripting standpoint. For amore thorough overview of components, consult the documentation that comes withFlash.A component is usually nothing more than a movie clip with some built-in functionality.Components can be customized using ActionScript in two ways: • You add components to a project manually by dragging them onto the stage within Flashs authoring environment, via the Property Inspector or Component Inspector. • You add components to a project dynamically using ActionScript while the movie plays.When a component is added by either technique, youre actually placing an instance ofthat component type/class into your project. For example, if you drag and drop aCheckBox component onto the stage in the authoring environment, that object isconsidered to be a CheckBox component instance. As when using other object instances,you assign names to component instances; the instance name can be used in your scriptsto communicate with that component instance.A number of user interface components ship with Flash. These components allow you tocreate forms and menus, or to display information and visual content in interactive ways.Flash also ships with data components and media components. Data components providea relatively easy way of working with the data in your application, especially sending andretrieving external data. Media components enable you to display and control theplayback of media elements such as video and MP3 files. The primary focus of thislesson involves using and working with user interface components. Youll learn aboutmedia element component types in later lessons.As you learn throughout this lesson, most components share some commonfunctionalities and capabilities. As a result, the common ActionScript syntax works in thesame way no matter what component instance youre scripting. At the same time, eachtype of component is built to be used for a specific purpose; thus, each type of componenthas some unique ActionScript commands.Using ActionScript, you can do any of the following: • Configure a component instance while your movie plays • Tell the component instance to react to a specific event • Retrieve data from a component instance • Change the appearance of a component instanceIn the exercises in this lesson, youll implement each of these types of interactivity in thecreation of a URL manager, which is used as a mini-database for Web, FTP, and emailaddresses. The result will be a highly interactive application, requiring relatively littlescripting to make it work. < Day Day Up >

Tài liệu được xem nhiều: