Rhodes-按下按钮时创建一个动作
我想在按下屏幕上的按钮时增加变量的值,但我不知道该怎么做。 rhodes 中是否有类似 .click
或类似方法,以便当用户单击按钮时变量值应该递增?
I want to increment the value of a variable when a button is pressed on the screen, but I don't know how can I do that. Is there a method in rhodes like .click
or something like that so that when the user clicks the button the variable value should be incremented?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您是从头开始做这件事还是有一些代码可以显示以帮助我们了解您正在做的事情的整体概念?在本机 Jquery 中,我在下面的代码中提供了您的要求。据我了解,rhodes 配备了 Jquery,您应该能够使用它的本机控件。
HTML:
JQuery:
Fiddle:
http://jsfiddle.net/GvGoldmedal/KFax4/
Are you starting from scratch on this or do you have some code you can display to help us get a concept of what you're doing as a whole? In native Jquery what your asking I've provided in the code below. It's my understanding that rhodes comes equipped with Jquery and you should be able to use it's native controls.
HTML:
JQuery:
Fiddle:
http://jsfiddle.net/GvGoldmedal/KFax4/