文件名称:
PROGRAMMING ACTIONSCRIPT 3.0
开发工具:
文件大小: 7mb
下载次数: 0
上传时间: 2009-05-30
详细说明: About this manual 13 Using this manual..14 Accessing ActionScript documentation15 ActionScript learning resources.. 17 Chapter 1: Introduction to ActionScript 3.0.. 19 About ActionScript..19 Advantages of ActionScript 3.0.20 What’s new in ActionScript 3.0.. 21 C ore language features...21 Flash Player API features...23 Compatibility with previous versions24 Chapter 2: Getting started with ActionScript..27 Programming fundamentals27 What computer programs do..27 Variables and constants...28 Data types...29 Working with objects.. 31 Properties...31 Methods32 Events33 Basic event handling...34 Examining the event-handling process... 35 Event-handling examples.. 39 Creating object instances...40 Common program elements..42 Example: Animation portfolio piece44 Building applications with ActionScript.47 Options for organizing your code48 Choosing the right tool...50 The ActionScript development process 51 Creating your own classes...53 Strategies for designing a class. 53 Writing the code for a class..54 4 Suggestions for organizing your classes...56 Example: Creating a basic application 56 Running subsequent examples.. 63 Chapter 3: ActionScript language and syntax.67 Language overview..68 Objects and classes.69 Packages and namespaces... 70 Packages...70 Namespaces..75 Variables83 Data types87 Type checking..88 Dynamic classes..93 Data type descriptions94 Type conversions.97 Syntax 103 Operators 109 Conditionals...117 Looping119 Functions 122 Basic function concepts... 122 Function parameters 128 Functions as objects 134 Function scope.135 Chapter 4: Object-oriented programming in ActionScript.137 Basics of object-oriented programming 138 Classes140 Class definitions..141 Class property attributes... 144 Variables...147 Methods...148 Enumerations with classes..156 Embedded asset classes...158 Interfaces 158 Inheritance162 Advanced topics..171 Example: GeometricShapes..180 5 Chapter 5: Working with dates and times... 191 Basics of dates and times191 Managing calendar dates and times193 Controlling time intervals196 Example: Simple analog clock...199 Chapter 6: Working with strings203 Basics of strings.. 204 Creating strings... 205 The length property. 207 Working with characters in strings208 Comparing strings.208 Obtaining string representations of other objects.209 Concatenating strings209 Finding substrings and patterns in strings210 Converting strings between uppercase and lowercase215 Example: ASCII art..216 Chapter 7: Working with arrays223 Basics of arrays... 223 Indexed arrays...225 Associative arrays.234 Multidimensional arrays...239 Cloning arrays...241 Advanced topics..241 Example: PlayList..247 Chapter 8: Handling errors. 253 Basics of error handling...254 Types of errors..257 Error handling in ActionScript 3.0259 ActionScript 3.0 error-handling elements..260 Error-handling strategies...261 Working with the debugger version of Flash Player.261 Handling synchronous errors in an application.. 262 Creating custom error classes.. 267 Responding to error events and status268 6 Comparing the Error classes...272 ECMAScript core Error classes..272 ActionScript core Error classes.275 flash.error package Error classes276 Example: CustomErrors application278 Chapter 9: Using regular expressions...285 Basics of regular expressions..286 Regular expression syntax288 Creating an instance of a regular expression..289 Characters, metacharacters, and metasequences 290 Character classes.293 Quantifiers..295 Alternation...297 Groups297 Flags and properties. 301 Methods for using regular expressions with strings.305 Example: A Wiki parser...306 Chapter 10: Handling events313 Basics of handling events...314 How ActionScript 3.0 event handling differs from earlier versions317 The event flow..320 Event objects...322 Event listeners...327 Example: Alarm Clock335 Chapter 11: Working with XML343 Basics of XML..344 The E4X approach to XML processing348 XML objects... 350 XMLList objects...353 Initializing XML variables354 Assembling and transforming XML objects356 Traversing XML structures...358 Using XML namespaces363 XML type conversion.364 Reading external XML documents.366 Example: Loading RSS data from the Internet..367 7 Chapter 12: Display programming371 Basics of display programming.372 Core display classes377 Advantages of the display list approach 379 Working with display objects..382 Properties and methods of the DisplayObject class...382 Adding display objects to the display list... 383 Working with display object containers...383 Traversing the display list..387 Setting Stage properties..389 Handling events for display objects392 Choosing a DisplayObject subclass393 Manipulating display objects..395 Changing position395 Panning and scrolling display objects 400 Manipulating size and scaling objects402 Controlling distortion when scaling 403 Caching display objects... 405 When to enable caching.. 406 Enabling bitmap caching.. 408 Setting an opaque background color...409 Applying blending modes...409 Adjusting DisplayObject colors..410 Setting color values with code411 Altering color and brightness effects with code.412 Rotating objects..413 Fading objects..413 Masking display objects...414 Animating objects...416 Loading display content dynamically418 Loading display objects...419 Monitoring loading progress.420 Specifying loading context..421 Example: SpriteArranger...423 Chapter 13: Working with geometry431 Basics of geometry.431 Using Point objects. 434 Using Rectangle objects436 Using Matrix objects440 Example: Applying a matrix transformation to a display object.442 8 Chapter 14: Using the drawing API...447 Basics of using the drawing API..448 Understanding the Graphics class450 Drawing lines and curves...450 Drawing shapes using built-in methods453 Creating gradient lines and fills..454 Using the Math class with drawing methods..460 Animating with the drawing API.461 Example: Algorithmic Visual Generator462 Chapter 15: Filtering display objects...465 Basics of filtering display objects..465 Creating and applying filters...467 Creating a new filter467 Applying a filter..467 How filters work..470 Potential issues for working with filters470 Available display filters472 Bevel filter473 Blur filter474 Drop shadow filter..474 Glow filter...475 Gradient bevel filter.476 Gradient glow filter477 Example: Combining basic filters478 Color matrix filter. 480 Convolution filter.481 Displacement map filter484 Example: Filter Workbench...490 Chapter 16: Working with movie clips 491 Basics of movie clips491 Working with MovieClip objects.. 494 Controlling movie clip playback.494 Working with scenes497 Creating MovieClip objects with ActionScript.. 498 Exporting library symbols for ActionScript..498 Loading an external SWF file..501 Example: RuntimeAssetsExplorer503 9 Chapter 17: Working with text 509 Basics of working with text510 Displaying text513 Types of text...513 Modifying the text field contents.514 Displaying HTML text514 Using images in text fields...515 Scrolling text in a text field...516 Selecting and manipulating text..517 Capturing text input.518 Restricting text input520 Formatting text..520 Assigning text formats521 Applying cascading style sheets..521 Loading an external CSS file..523 Formatting ranges of text within a text field... 524 Advanced text rendering525 Working with static text528 Example: Newspaper-style text formatting... 529 Reading the external CSS file.530 Arranging story elements on the page...532 Altering font size to fit the field size533 Splitting text across multiple columns535 Chapter 18: Working with bitmaps539 Basics of working with bitmaps..540 The Bitmap and BitmapData classes543 Manipulating pixels.. 545 Manipulating individual pixels.545 Pixel-level collision detection.547 Copying bitmap data549 Making textures with noise functions550 Scrolling bitmaps.552 Example: Animating sprites using an offscreen bitmap...553 Chapter 19: Working with video555 Basics of video..556 Understanding the Flash Video (FLV) format..559 Understanding the Video class.560 Loading video files..561 Controlling video playback... 562 Detecting the end of a video stream563 10 Streaming video files.564 Understanding cue points...565 Writing callback methods for onCuePoint and onMetaData..566 Set the NetStream object’s client property to an Object...567 Create a custom class and define methods to handle the callback methods.568 Extend the NetStream class and add methods to handle the callback methods569 Extend the NetStream class and make it dynamic570 Set the NetStream object’s client property to this.572 Using cue points..572 Using video metadata.573 Capturing camera input 577 Understanding the Camera class577 Displaying camera content on-screen578 Designing your camera application.578 Connecting to a user’s camera..578 Verifying that cameras are installed.579 Detecting permissions for camera access..580 Maximizing video quality...582 Monitoring playback conditions..583 Sending video to a server...584 Advanced topics..585 Flash Player compatibility with encoded FLV files585 About configuring FLV files for hosting on a server585 About targeting local FLV files on the Macintosh.586 Example: Video Jukebox587 Chapter 20: Working with sound 595 Basics of working with sound.. 596 Understanding the sound architecture599 Loading external sound files..600 Working with embedded sounds. 603 Working with streaming sound files 604 Playing sounds..605 Pausing and resuming a sound606 Monitoring playback.607 Stopping streaming sounds.609 Security considerations when loading and playing sounds..609 Controlling sound volume and panning.611 Working with sound metadata.. 613 Accessing raw sound data 614 Capturing sound input617 11 Accessing a microphone... 617 Routing microphone audio to local speakers...619 Altering microphone audio...619 Detecting microphone activity. 620 Sending audio to and from a media server621 Example: Podcast Player...622 Reading RSS data for a podcast channel..623 Simplifying sound loading and playback using the SoundFacade class.623 Displaying playback progress.627 Pausing and resuming playback.628 Extending the Podcast Player example...629 Chapter 21: Capturing user input.631 Basics of user input.631 Capturing keyboard input...633 Capturing mouse input 636 Example: WordSearch641 Chapter 22: Networking and communication645 Basics of networking and communication...646 Working with external data...649 Connecting to other Flash Player instances...656 Socket connections. 662 Storing local data.668 Working with file upload and download671 Example: Building a Telnet client. 682 Example: Uploading and downloading files... 685 Chapter 23: Client system environment..695 Basics of the client system environment695 Using the System class 698 Using the Capabilities class..699 Using the ApplicationDomain class700 Using the IME class. 704 Example: Detecting system capabilities 709 12 Chapter 24: Printing... 715 Basics of printing..716 Printing a page..718 Flash Player tasks and system printing719 Setting size, scale, and orientation.722 Example: Multiple-page printing.725 Example: Scaling, cropping, and responding..727 Chapter 25: Using the external API...731 Basics of using the external API..732 External API requirements and advantages...735 Using the ExternalInterface class..736 Getting information about the external container737 Calling external code from ActionScript...737 Calling ActionScript code from the container...739 The external API’s XML format.740 Example: Using the external API with a web page container..742 Example: Using the external API with an ActiveX container..749 Chapter 26: Flash Player security757 Flash Player security overview..758 Overview of permission controls.760 Security sandboxes.. 770 Restricting networking APIs..773 Full-screen mode security...775 Loading content... 776 Cross-scripting...779 Accessing loaded media as data.783 Loading data786 Loading embedded content from SWF files imported into a security domain..788 Working with legacy content..789 Setting LocalConnection permissions.790 Controlling access to scripts in a host web page..790 Shared objects...792 Camera, microphone, clipboard, mouse, and keyboard access.794 ...展开收缩
(系统自动生成,下载前可以参看下载内容)
下载文件列表
相关说明
- 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
- 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度。
- 本站已设置防盗链,请勿用迅雷、QQ旋风等多线程下载软件下载资源,下载后用WinRAR最新版进行解压.
- 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
- 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
- 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.