Ext.onReady(function(){
//一.alert 对话框,参数(标题,内容)
//二.prompt 对话框 参数(标题,内容,回调函数,scope,是否多行[ok or cancel])
//三.confirm 确认框 参数(标题,内容,回调函数 yes or no)
//四.progress 进度条 参数(标题,内容,进度条内容)
// 调用updateProgress方法可以更新进度的内容
// 调用hide方法来隐藏所有msg内容.
//五.自定义对话框
// show({})方法,加一些配置项,主要是title,msg,buttons,icon,fn之类
//六.行为
// 其它一些配置,如progress:ture 相当于progress,prompt相当于prompt.modal模态窗口.fn
//七.window窗口
//1.window的msg的父类,可以使用window来自定义一些信息,展示.
//八.panel相关.(window的父类)
// @layout配置,同panel设置
// @items配置:用数组.用form的组件
// @autoWidth:true,自动设置宽度
// @autoHeight:true,自动设置高度
// @maximizable 自动最大化
// @minimizable 最小化,必须自动实现方法
// @collapsible 可折叠
// @expandOnShow 显示时展示信息
// @tbar 配置
// @bbar配置
// @buttons 配置
//九.其它一些方法及事件
// @minimize事件,最小化时处理
// @restore从最大化到原始大小的处理
// @toggleMaximize最大化处理.
// @center in the middle of browser's viewport
//十.事件
// 1.stateful: true,状态记忆
// 2.stateevents:['minimize','maximize']记忆事件
//十一.window窗口管理
//
// //提示
// Ext.Msg.alert("标题","内容");
// //提示框
// Ext.Msg.prompt("提示框","内容",function(btn,text){
// if(btn == "ok"){
// console.debug(text);
// }else if(btn == "cancel"){
// console.debug("cancel");
// }
// },this,false);
// //确认框
// Ext.Msg.confirm("标题","内容",function(btn,text){
// if(btn == "yes"){
// console.debug("yes!!!");
// }
// });
// //进度条
// Ext.Msg.progress("标题","测试","正在下载...");
// var count = 0;
// var interval = window.setInterval(function(){
// count += 0.04;
// Ext.Msg.updateProgress(count,Math.ceil(count*100) + "%");
// if(count > 1){
// window.clearInterval(interval);
// Ext.Msg.hide();
// }
// },1000);
//
// //自定义
// Ext.Msg.show({
// title:"自定义标题",
// msg:"自定义对话框",
// icon:Ext.MessageBox.INFO,
// buttons:{yes:true,no:true,cancel:true},
// width: 300
// });
// //行为
// Ext.Msg.show({
// title : "测试",
// msg : "内容",
// prompt : true,
// multiline : true,
// buttons:Ext.Msg.YESNO
// });
//window配置
var w = new Ext.Window({
width:200,
height:300,
// autoWidth:true,
// autoHeight:true,
title:"测试窗口",
html:"<b>Test</b><hr/>context hereontext hereontext hereontext hereontext hereontext here<br/>" +
"ontext hereontext hereontext hereontext hereontext hereontext hereontext hereontext here<br/>" +
"ontext hereontext hereontext hereontext hereontext hereontext here<br/>" +
"ontext hereontext hereontext hereontext hereontext here<br/>",
maximizable:true,
minimizable:true,
collapsible:true,
expandOnShow:false,
tbar:[{text:"top bar"}],
bbar:[{text:"bottom bar"}],
buttons:[{text:"check"}],
stateful: true,
stateevents:['minimize','maximize']
});
w.show("txtNull", function() {
//alert("test")
});
w.on("minimize",function(){
// console.debug("minimize");
w.collapse(false);
w.alignTo(document.body,"bl-bl");
});
// w.on("maximize",function(){
// console.debug("maximize");
// });
w.on("restore",function(){
console.debug("restore");
});
// w.on("maximize",function(){
// console.debug("maximize");
// });
//panel特征及配置
// var wp = new Ext.Window({
// layout:"form",
// items:[
// {
// xtype:"textfield",
// fieldLabel:"姓名"
// },
// new Ext.form.TextField({fieldLabel:"地址"})
// ],
// width:300,
// height:200,
// closable:false,
// draggable:false,
// resizable:false
// });
// wp.show();
});
详细解决方案
LearningExtJS_new 之 windows and dialog 的运用学习(七) PART I
热度:698 发布时间:2012-10-11 10:16:10.0
相关解决方案
- my lovely windows , see you!该如何处理
- Windows Mobile开发中的有关问题
- Windows Moblie5上是否有完整兼容的J2SDK1.4或5.0版本的虚拟机?解决思路
- windows mobile中j2me的疑问,该怎么解决
- Socket通讯 windows mobile操作系统支持吗
- windows mobile 6.1下有支持蓝牙传输的java虚拟机吗?解决思路
- jdk-6u7-windows-i586-p.exe 后边的-p是什么意思
- 用Java 写一个乘法表如图所示,要求part one 使用一个while循环 part two 使用for嵌套循环解决办法
- 使用Jquery.ui.Dialog 插件和jquery Ztree 2个插件 样式乱了解决思路
- Windows 8之父Steven Sinofsky将离开微软,微软官方已确认解决方法
- Windows 八之父Steven Sinofsky将离开微软,微软官方已确认
- Windows Form 中怎么将 treeview 的节点与页面内容关联
- InputMan for Windows Forms 5.0J 试用版的等待时间有关问题
- DevExpress的WinForm控件都沿袭自System.Windows.Forms.Contrl吗
- Free Windows Forms Controls——Krypton Toolkit解决思路
- ActiveX 安装出现 Windows Installer 有关问题
- vc写的 windows service 控制台程序有关问题
- c++/cli windows form有关问题
- Windows media player控件编程播放avi只有声音没图像啊解决方案
- 求VC++ 2008 >> CLR >> Windows 窗体应用程序实例,该如何处理
- windows 窗口进程lParam参数的,高低两个宏定义
- CLR Windows Forms Aoolication 程序怎么创建新的Dialog
- j# 里如何定义和 C#同样功能的 override void DefWndProc(ref System.Windows.Forms.Message m) 多谢,很
- dundas chart for windows 怎么调整柱状图的宽度,怎么设置柱状图的起止点
- windows service装配服务程序
- windows server 2008 + IIS 7.5 上 网站自定义权限过滤有关问题
- C# windows services 使用IDictionary 有关问题?
- CS0016: 未能写下输出文件“c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary
- windows 8 的搜索是不是有有关问题?是不是个新Bug
- windows azure 的一个非常初级的有关问题