Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/32.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Css 如何更改选项卡栏图标包括sencha touch中选择的相应选项卡栏项目_Css_Html_Sencha Touch_Sencha Touch 2 - Fatal编程技术网

Css 如何更改选项卡栏图标包括sencha touch中选择的相应选项卡栏项目

Css 如何更改选项卡栏图标包括sencha touch中选择的相应选项卡栏项目,css,html,sencha-touch,sencha-touch-2,Css,Html,Sencha Touch,Sencha Touch 2,我已经使用SenchaTouch2完成了应用程序。在我想向用户显示的选项卡栏中,一旦我从选项卡栏中选择了项目,然后需要将普通图像更改为所选图像。现在我正在通过sass样式进行操作。普通图像很好,但当我选择/激活项目时。它不会将普通图标更改为选定图标。我去了一些我已经申请的文章,它对我不起作用。下面我给出了代码。谁能告诉我如何实现这一目标 查看页面代码: config: { tabBarPosition: 'bottom', items: [{ iconCls: 'Ap

我已经使用SenchaTouch2完成了应用程序。在我想向用户显示的选项卡栏中,一旦我从选项卡栏中选择了项目,然后需要将普通图像更改为所选图像。现在我正在通过sass样式进行操作。普通图像很好,但当我选择/激活项目时。它不会将普通图标更改为选定图标。我去了一些我已经申请的文章,它对我不起作用。下面我给出了代码。谁能告诉我如何实现这一目标

查看页面代码:

config: {
tabBarPosition: 'bottom',
items: [{      
        iconCls: 'ApartmentIcon',
        autoDestroy:true,
        layout:{
            type:'vbox',
            pack:'center'
        },
        scrollable: true,       
        fullscreen:true,
            items: [
                     {
                      //Some items
                     }
                  ]
       }
   ]
}
Css代码:我在下面介绍了四种方法,但一旦选择,图像就不会改变。

.ApartmentIcon{
  @include image-tabIcon('data:image/png;base64,NormalimageBase64code....=',70px,90px);
}

ApartmentIcon.x-button-pressing{
  @include image-tabIcon('data:image/png;base64,SelectedimageBase64code....=',70px,90px);
}
.ApartmentIcon.x-tab-active{
  @include image-tabIcon('data:image/png;base64,SelectedimageBase64code....=',70px,90px);
}
.ApartmentIcon.selected{
  @include image-tabIcon('data:image/png;base64,SelectedimageBase64code....=',70px,90px);
}
.x-tabbar-dark.x-docked-bottom .x-tab-active:first-child{
  @include image-tabIcon('data:image/png;base64,SelectedimageBase64code....=',70px,90px);
}

你能试试.x-tab-active.ApartmentIcon{…}x-tab-active.ApartmentIcon{@include image tabIcon('data:image/png;base64,SelectedimageBase64code..=',70px,90px);}@tdebaileul..我已经按你说的那样试过了。它不起作用。请任何人告诉我怎么做这个。