Results 1 to 2 of 2

Thread: Displaying context menu

  1. #1
    Join Date
    Jul 2013

    Displaying context menu

    I had already developed the js code that allowed me to display the context menu through another action. For example, by left clicking or pressing a key.

    I managed to do what I wanted for most elements except for some like the mails in gmail or hotmail. When you right-click, there is a small menu with "archive" or "mark as unread" for example. What I would like to do is force the display of the classic menu on these too.

    Here is the code I have so far:
    var displayingMenu = function(element, event)
        var Event = element.ownerDocument.createEvent('MouseEvents');
        Event.initMouseEvent('contextmenu', true, true, element.ownerDocument.defaultView, 1, event.screenX, event.screenY, event.clientX, event.clientY, false, false, false, false, 2, null);
    With that, on an email in gmail for example I still have the special menu "archive" etc ...
    Do you have any idea about how I could do to reach my goal?

  2. #2
    Join Date
    Jul 2013
    A little up

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center