Flash Builder AIR 项目背景图片 [英] Flash Builder AIR Project Background Image

查看:24
本文介绍了Flash Builder AIR 项目背景图片的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对 Flash Builder 非常陌生,正在尝试创建具有自定义背景的 AIR 应用程序.如何在我的项目中放置背景图像?我试过只将图像放在设计视图中,但在我运行项目时它从未出现过.

I'm very new to Flash Builder and am trying to create an AIR app with a custom background. How can I put a background image in my project? I've tried just placing the image in the design view but it never shows up when I run the project.

推荐答案

自己修复,添加<代码>@Embed(source='/path/to/file.jpg')而不是浏览功能放置的内容:<代码>/path/to/file.jpg我从看到按钮(显示)上的图标是如何编写的中得到了这个想法.

Fixed it myself, by adding @Embed(source='/path/to/file.jpg') instead of what the browse function put: /path/to/file.jpg I got the idea from seeing how the icon on a button (which showed up) was written.

经过一些修改后,似乎/path/to/file 也能正常工作,只要该文件位于 src 目录下,并且将非嵌入文件复制到输出文件夹"已签入Flex Compiler 下的 Project 属性.

After some more tinkering, it seems that /path/to/file works just as well, as long as the file is under the src directory, and that "Copy non-embedded files to output folder" is checked in the Project properties under Flex Compiler.

这篇关于Flash Builder AIR 项目背景图片的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆