flash如何获得自身在页面中的长宽
http://www.top000.com/mp3.html
这个页面中,里面那个播放器的swf本身的长宽是:360x50.
这里是这个页面的源代码:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh_cn" lang="zh_cn">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>Mp3</title>
<embed src="http://www.top000.com/mp3.swf?songs=1|55|555&color=0xff0000" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="447" height="50"></embed>
</body>
</html>
看到那个width="447" height="50"
宽度由360被拉到447了,看到2边出现flash的背景色绿色,flash里面有没办法可以获取自身现在的宽度?也就是447这个宽度?因为我想根据flash在页面中的宽度来设置那个播放器的宽度和高度。有人懂的话请告诉我吧~~谢谢~~
答案:禁止缩放 然后stageWidth stageHeight 就是
stage.scaleMode=StageScaleMode.NO_SCALE;
相关文档:
var aa:Boolean = true;
my_btn.onPress = function() {
if (aa == true) {
fscommand("fullscreen", true);
aa = false;
} else {
fscommand("fullscreen", false);
aa = true;
}
};
my_btn是一个按钮 ......
这几天,都在无所事事,唯一寄托就是在这里记录一下自己研究出来的东西。趁现在有点时间,就把最近看过的一种常用的flash特效记录一下,flash 做特效不是为做特效而做,在make thing move 书里讲了许多的数学和物理原理,通过这些原理,我发现做特效就需要懂原理。懂了这些原理后,特效就会变得轻松容易。
现 ......
Ubuntu下装完Adobe的Flash插件后,浏览器里可以播放Flash动画了。但是还存在一个问题就是汉字无法正确显示,显示为方格
解决办法:
修改这个配置文件
/etc/fonts/conf.d/49-sansserif.conf
把其中所有的字体名替换为中文字体名即可,我这里用的是“微软雅黑”和“Consolas“。
<?xml version=" ......
昨天看了IBM网站上写到rcp中运行open flash chart觉得不错自己就试着写了一下。
package com.chart.test;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.FillLayout;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.ole.win32.OLE;
import org.eclipse.swt.ole.win32.OleAutomation; ......