如何在点击事件中在菜单中显示子菜单 [英] how to show submenu in menu in click event

查看:55
本文介绍了如何在点击事件中在菜单中显示子菜单的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个菜单,我想要的是,当我单击菜单的父项时,只有子项目应该显示,意味着我不想在鼠标悬停时显示子项目.我该怎么办.是否应该设置任何属性,或者我必须为其编写代码,请提供帮助.

i have a menu, what i want is that when i click on parent item of menu then only subitem should display,mean i dont want to display subitem on mouseover. what should i do.Is there any property should i set or i have to write code for it please help.

推荐答案

那真是微不足道.你试过了吗?谷歌? CP搜索?

您只需要将鼠标悬停代码置于click事件中即可.无需其他更改.如果可以获得/知道鼠标悬停代码,则可以单击.

顺便说一句,没有直接财产.对于鼠标悬停类功能,代码会在其悬停上编写.您的点击事件.

试试吧!
Thats pretty trivial. Did you try? Google? CP search?

What you need is just to put the mouseover code in click event. No more change required. If you can get/know mouseover code, you can do for click.

BTW, no direct property. For mouseover kinda feature, code is written on its hover. In your case its click event.

Try!


这篇关于如何在点击事件中在菜单中显示子菜单的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆