Embeding images in an Flex application

后端 未结 2 597
感情败类
感情败类 2021-01-23 16:53

I use the images in the tooltips. Images are on the server. I\'m using the code:

    var tip1:String;
    tip1 = \"

        
2条回答
  •  北荒
    北荒 (楼主)
    2021-01-23 17:08

    It certainly is. Add the images you want to include in your Flex app, then embed them in your code like this:

    
      
        
    
    
    

    If you really want to use this in a toolTip, here's a good article on how to do that: http://blog.flexmp.com/2008/09/10/flex-custom-tooltip-speech-bubble/

    EDIT: Here's a quick and dirty example of how to preload your images into an ArrayCollection when your application starts. You'll want to add some code to make sure all of your images are loaded before enabling the application or performing some other action, but again this should get you started.

    
    
        
            
        
    
    

    Another good component you may want to check out is the Flex BulkLoader created by Arthur Debert. It may also work well for your needs.

    https://github.com/arthur-debert/BulkLoader

提交回复
热议问题