如何在sencha touch2中聚焦/突出显示工具栏元素内部

时间:2012-07-18 12:56:34

标签: sencha-touch extjs sencha-touch-2

我使用sencha touch2完成了应用程序。根据要求当鼠标结束(指向)特定元素时,我需要在工具栏元素内聚焦/突出显示。我已经添加了pressCls,它将在我按下后工作,但我需要在鼠标上突出显示。可以告诉我如何实现这一目标。

这是我的代码:

initialize:function () {
    this.callParent(arguments);
    var Button1 = {
        xtype:"button",
        id: 'suvilasBtn',            
        html: '<img  height="30" width="40", src="resources/sass/images/icons/about.png" />',            
        pressedCls: 'customPressedCls',            
        scope:this
    };
    var Button2 = {
        xtype: "button",
        id: 'projectBtn',
        html: '<img  height="30" width="40", src="resources/sass/images/icons/projects.png" />',
        handler: this.onProjectsButtonTap,
        scope: this
    };
    var bottomToolbar = {
        xtype:"toolbar",
        docked:"bottom",
        scrollable: false,                      
        defaults: {
            iconMask: true,
            ui: 'plain'
        },
        layout: {
            pack : 'center',
            align: 'center'
        },
        items:[
            Button1,
            Button2
        ]
    };
    this.add([ bottomToolbar ]);
}

0 个答案:

没有答案
相关问题