sencha touch mvc
controller:
Ext.define('MyApp2.controller.MyController1', {
extend: 'Ext.app.Controller',
config: {
control: {
"#image2": {
tap: 'onImageTap'
}
}
},
onImageTap: function(image, e, eOpts) {
console.log('img2 tap');
}
});
view:
Ext.define('MyApp2.view.MainView', {
extend: 'Ext.carousel.Carousel',
alias: 'widget.mainview',
requires: [
'Ext.Panel',
'Ext.Label',
'Ext.Img'
],
config: {
itemId: 'mainView',
items: [
{
xtype: 'panel',
itemId: 'panel1',
items: [
{
xtype: 'label',
centered: true,
html: 'Panel 1',
itemId: 'label1'
},
{
xtype: 'image',
height: 201,
id: 'image1',
itemId: 'image1',
src: 'images/sencha.png'
}
]
},
{
xtype: 'panel',
itemId: 'panel2',
items: [
{
xtype: 'label',
centered: true,
html: 'Panel 2',
itemId: 'label2'
},
{
xtype: 'image',
height: 201,
id: 'image2',//reference this id to attach event handler
itemId: 'image2',
src: 'images/sencha.png'
}
]
},
{
xtype: 'panel',
itemId: 'panel3',
items: [
{
xtype: 'label',
centered: true,
html: 'Panel 3',
itemId: 'label3'
},
{
xtype: 'image',
height: 201,
itemId: 'image3',
src: 'images/sencha.png'
}
]
},
{
xtype: 'panel',
itemId: 'panel4',
items: [
{
xtype: 'label',
centered: true,
html: 'Panel 4',
itemId: 'label4'
},
{
xtype: 'image',
height: 201,
itemId: 'image4',
src: 'images/sencha.png'
}
]
}
]
}
});
sencha touch mvc的更多相关文章
- Sencha Touch MVC 中 store 的使用
I have a UserStore that I want to load after succesful login of a user. I can't get this to work i.e ...
- 跟我一起玩转Sencha Touch 移动 WebApp 开发(一)
1.目录 移动框架简介,为什么选择Sencha Touch? 环境搭建 创建项目框架,框架文件简介 创建简单Tabpanel案例 自定义图标的方式 WebApp产品测试和发布 HTML5离线缓存 发布 ...
- Sencha Touch+PhoneGap打造超级奶爸之喂养记(一) 源码免费提供
起源 非常高兴我的宝宝健康平安的出生了.对于初次做奶爸的我,喜悦过后,面临着各中担心,担心宝宝各项指标是否正常.最初几天都是在医院待着,从出生那一天开始,护士妹妹隔一段时间就会来问宝宝的喂奶,大小便, ...
- jQuery Mobile和Sencha Touch哪个更适合你?
纯粹的总结一下移动web开发框架,移动web开发框架有jQuery Mobile .Sencha Touch等等,他们都来源于web开发,是成熟的框架,jQuery Mobile出自于jQuery家族 ...
- (转)Sencha Touch和jQuery Mobile的比较
原文:http://extjs.org.cn/node/664 Sencha Touch和jQuery Mobile的比较 Posted 周三, 08/07/2013 - 10:07 by admin ...
- html5外包—长年承接html5外包业务:《Sencha Touch权威指南》下载
<Sencha Touch权威指南>内容简介:如何才能全面而透彻地理解和掌握移动应用开发框架Sencha Touch并开发出令人心动的移动应用?<Sencha Touch权威指南&g ...
- Sencha Touch 和 jQuery Mobile 的比较
Sencha Touch 和 jQuery Mobile 的比较 英文原文:Sencha Touch vs jQuery Mobile 标签: Sencha Touch jQuery Mobile 1 ...
- 跟我一起玩转Sencha Touch 移动 WebApp 开发1
跟我一起玩转Sencha Touch 移动 WebApp 开发(一) 1.目录 移动框架简介,为什么选择Sencha Touch? 环境搭建 创建项目框架,框架文件简介 创建简单Tabpanel案例 ...
- sencha touch 入门学习资料大全(2015-12-30)
现在sencha touch已经更新到2.4.2版本了 重新整理一下资料 官方网站:http://www.sencha.com/products/touch/ 在线文档:http://docs.sen ...
随机推荐
- Flume简介与使用(三)——Kafka Sink消费数据之Kafka安装
前面已经介绍了如何利用Thrift Source生产数据,今天介绍如何用Kafka Sink消费数据. 其实之前已经在Flume配置文件里设置了用Kafka Sink消费数据 agent1.sinks ...
- Linux系统常见的压缩命令
*.Z compress 程序压缩的文件: //在当前的Linux主流版本中都已经默认没有支持该压缩命令了,因为gzip命令已经取代了compress命令了 *.gz gzip 程序压缩的文件: *. ...
- CentOS 7 gedit编辑器中文乱码解决方法
无需root登陆 打开终端输入如下命令: gsettings set org.gnome.gedit.preferences.encodings auto-detected "['GB180 ...
- hdu 1094 A+B for Input-Output Practice (VI)
A+B for Input-Output Practice (VI) Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/327 ...
- Android 常见adb命令
1. 查看所有已链接的设备 命令: adb devices 例: C:\Users\laiyu>adb devices List of devices attached 5d3b5aac ...
- mvn常见命令
http://www.cnblogs.com/adolfmc/archive/2012/07/31/2616908.html 创建一个简单的Java工程:mvn archetype:create -D ...
- 一个Notification 进度条插件(android,NJS实现,直接就可使用)
参考文章:http://ask.dcloud.net.cn/article/503 源码地址下载 如题,分享一个Notification 进度条插件(android,用js调用原生api实现,直接就可 ...
- webview中java与js交互
WebView提供了在Android应用中展示网页的强大功能.也是目前Hybird app的大力发展的基础.作为Android系统的一个非常重要的组件,它提供两方面的强大的能力:对HTML的解析,布局 ...
- redhat6.5 配置使用centos的yum源
新安装了redhat6.5安装后,登录系统,使用yum update 更新系统.提示: This system is not registered to Red Hat Subscription Ma ...
- js获取jsp中的变量值
js获取jsp中的变量值,有两种方式: 1.jsp标签获取属性 var message = '<%=request.getAttribute("message")%>' ...