Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
137 views
in Technique[技术] by (71.8m points)

Right mouse click in web applications: good or bad idea?

I'm currently working on a web application and the powers above have decided that overriding the browser's right-click menu with our own application-specific one is the way to go.

I totally disagree. I feel that when someone is using a web browser they have certain expectations about what should happen when they use the right-click functionality of a pointing device, and violating these expectations by purposefully supplanting this functionality is very disconcerting (annoying?) to the user.

What do you think? Have you ever seen right-click done well in a web app? I mean in a way that you actually thought, "Yes, this right-click functionality was a great decision."?

question from:https://stackoverflow.com/questions/779689/right-mouse-click-in-web-applications-good-or-bad-idea

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

It's generally not a good idea:

Expectations

Users, especially power users, expect to be able to right-click on elements in desktop applications in order to get a menu of element-specific actions. This expectation does not exist for web applications - indeed, the expectation is that right-clicking in a web page will give you the standard web-page menu where you can print, open links in new windows, view source, etc.

Reliability

Because the ability to override built-in menus has been so abused in the past (mostly by naive programmers attempting to disable saving images), many browsers prohibit it or make it difficult for client code to override in a reliable fashion.

The Exception

If you are creating a web app that closely simulates the behavior of an existing and well-known desktop app, it may be appropriate to put the effort in required to implement sensible right-click menus. However, you should then also follow the usual recommendation for these menus in desktop apps: use them to provide quick access to context-specific operations, but also provide another means of accessing the same features.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...