`

Alert 和 style

阅读更多

http://hi.baidu.com/zhao_gw/blog/item/ddb4f7d18c7226349b5027d9.html

 

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"
        creationComplete="showAlert();">
 
    <mx:Script>
        <![CDATA[
            import mx.controls.Alert;
 
            private var alert:Alert;
 
            private function showAlert():void {
                alert = Alert.show("The quick brown fox jumped over the lazy dog.", "title");
            }
        ]]>
    </mx:Script>
 
    <mx:Style>
        Alert {
            backgroundAlpha: 0.3;
            backgroundColor: red;
            borderAlpha: 0.3;
            borderColor: red;
            dropShadowEnabled: false;
        }
    </mx:Style>
 
    <mx:ApplicationControlBar dock="true">
        <mx:Button label="Show alert" click="showAlert();" />
    </mx:ApplicationControlBar>
 
</mx:Application>

 

 

http://flexmusings.wordpress.com/2008/01/21/using-same-color-for-border-background-of-flex-alert-control/

 

 

 

<?xml version="1.0" encoding="utf-8"?>

<!-- giving colors to the text, border & background of an alert control-->

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
	layout="absolute"
	width="320"
	height="240"
	backgroundGradientColors="[#ffffff, #b0b0ff]"
	>

	<mx:Style>
		Alert{
			/*Change this to give different background colors
			{where the alert message is displayed}
			backgroundColor: #ffffff;*/

			backgroundColor: #b0b0ff;
			borderColor: #b0b0ff;
			color: #000000;
		}
	</mx:Style>

	<mx:Script>
		<![CDATA[
			import mx.controls.Alert;

			private var _alert:Alert;

			private function showAlert():void{
				_alert = Alert.show("The Alert message goes here","The Alert title goes here");
			}
		]]>
	</mx:Script>

	<mx:Button label="Show Alert" click="showAlert()" x="116" y="109"/>

</mx:Application>
分享到:
评论

相关推荐

    alert_style.zip_alert样式美化_style

    alert弹出窗口美化,支持html代码和样式等的操作。

    功能齐全的alert视图

    源码HLAlertController,一个非常简洁 但功能齐全的alert 用于替换系统的aler 主要是因为(ios 7 和ios 8的不同 需要调用不同的aler) 非常容易使用 [lang=objc] HLAlertController *alert = [HLAlertController ...

    vue一步步实现alert功能

    项目地址: web-style 项目里有css样式和vue组件。目标是快速构建后台系统。有一定自适应的设计。 css 思路:最外层是一个黑色透明撑满全屏幕的div并且是fixed的div.modal-mask。 在mask内部是一个垂直居中的div框...

    js的alert样式如何更改如背景颜色

    代码如下: window.alert = function(str) { var shield = document.createElement(“DIV”); shield.id = “shield”; shield.style.position = “absolute”; shield.style.left = “0px”; shield.style.top = “0...

    alert.js jQuery兼容电脑手机端弹出层插件.zip

    'style' : 'wap', //移动端和PC端 'title' : '', //标题 'content' : '', //内容 'contentTextAlign' : 'center', //内容对齐方式 'width' : 'auto', //宽度 'height' : 'auto', //高度 'minWidth' : '0', //...

    Teebo PopupNotify (Office and MSN Style Popup Alert Control for VB )

    PopupNotify is an ActiveX control that lets your applications display MSN, Office XP, and Office 2003 style popup alerts and notifications. Popup Notifications gracefully fade in and slide up above ...

    appcompat-v7

    style ThemeOverlay_AppCompat_Dialog_Alert style ThemeOverlay_AppCompat_Light style Widget_AppCompat_ActionBar style Widget_AppCompat_ActionBar_Solid style Widget_AppCompat_ActionBar_TabBar style ...

    js重写alert事件(避免alert弹框标题出现网址)

    window.alert = function(msg, callback) { var div = document.createElement(div); div[removed] = &lt;style type=\text/css\&gt; + .nbaMask { position: fixed; z-index: 1000; top: 0; right: 0; left: 0...

    IOS微信端confirm以及alert去掉网址的实例代码

    在做微信公众号开发时IOS端的微信浏览器打开,触发confirm以及alert时弹出框会有... iframe.style.display=none; iframe.setAttribute(src, 'data:text/plain,'); document.documentElement.appendChild(iframe); windo

    flex 4.6Css

    Accordion | AdvancedDataGrid | Alert | Border | ColorPicker | DateChooser | HScrollBar | LinkBar LinkButton | Menu | MenuBar | PopUpButton | PopUpMenuButton | ProgressBar | TabNavigator ...

    jQuery基于函数重载实现自定义Alert函数样式的方法

    本文实例讲述了jQuery基于函数重载实现自定义Alert函数样式的方法。分享给大家供大家参考,具体如下: (function(){ ...div id="alertdiv" style="position:absolute; display:none ; overflow:hidden;

    判断客服端媒体设备

    alert &quot;安卓&quot; ul parentNode style width &quot;45%&quot;; }else if getPgjs &quot;ipad&quot; { alert &quot;平板&quot; ul parentNode style width &quot;90%&quot;; }else if getPgjs &quot;...

    用正则表达式 动态创建/增加css style script 兼容IE firefox

    str 是表示通过ajax返回的XMLRequest /*动态加载css style*/ function loadStyle(str) { var regExp_src=/&lt;style.*src\s*=\s*[“‘][^”‘]*[“‘].*&gt;[^&lt;&gt;]*&lt;\/style\s*&gt;/gi; var matchArray_src=str....

    jQuery实现弹窗居中效果类似alert&#40;&#41;

    效果图如下所示: 废话不多说了,直接给大家贴代码了,具体代码如下所示: ...style type="text/css"&gt; .mask { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #000; opacity: 0.5; fi

    js实现键盘控制图片的移动

    alert(id); } if(typeof GetControlundefined) GetControl=function (id) { return document.getElementById(id); }; function KeyDown() { var control=document....

    javascript重写alert方法的实例代码

    代码如下:&lt;!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” ...&lt;head&gt;&lt;... charset=utf-8″ /&gt; &lt;...重写alert&lt;...link href=”css/style.css

    修改js confirm alert 提示框文字的简单实例

    修改js confirm alert 提示框文字的简单实例 &lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head lang="en"&gt; &lt;meta charset="UTF-8"&gt; &lt;style&gt; *{padding: 0; margin: 0;} html{ height: 100%; } body...

    react-native-tooltip-alert

    react-native-tooltip-alert 展示iOS 展示Android 安装 npm i react-native-tooltip-alert --save 或者 yarn add react-native-tooltip-alert 例子 ... View style = { { flex : 1 , justifyContent

    计时器,HTML5的计时器设置。

    //alert("hello");弹出hello; //宽度每秒加50 num += 25; box.style.width = num + "px"; // //每过一秒,变颜色 // if (count == true) { // box.style.background = "green"; // count = false;...

    dtg.dialog.js:封装的alert,confirm

    封装的 alert,confirm 支持 jquery.js和zepto.js , 支持IE8以上浏览器 Alert使用方法: 1.默认样式 $.dtgAlert&#40;'这里是提示内容'&#41;; 2.默认样式自定义标题 $.dtgAlert&#40;'这里是提示内容','提示'&#41;; 3....

Global site tag (gtag.js) - Google Analytics