QContextMenuEvent Class Reference |
Constant | Value | Description |
---|---|---|
QContextMenuEvent::Mouse | 0 | The mouse caused the event to be sent. Normally this means the right mouse button was clicked, but this is platform dependent. |
QContextMenuEvent::Keyboard | 1 | The keyboard caused this event to be sent. On Windows, this means the menu button was pressed. |
QContextMenuEvent::Other | 2 | The event was sent by some other means (i.e. not by the mouse or keyboard). |
Constructs a context menu event object with the accept parameter flag set to false.
The reason parameter must be QContextMenuEvent::Mouse or QContextMenuEvent::Keyboard.
The pos parameter specifies the mouse position relative to the receiving widget. globalPos is the mouse position in absolute coordinates.
Constructs a context menu event object with the accept parameter flag set to false.
The reason parameter must be QContextMenuEvent::Mouse or QContextMenuEvent::Keyboard.
The pos parameter specifies the mouse position relative to the receiving widget.
The globalPos() is initialized to QCursor::pos(), which may not be appropriate. Use the other constructor to specify the global position explicitly.
Returns the global position of the mouse pointer at the time of the event.
Returns the global x position of the mouse pointer at the time of the event.
See also globalY() and globalPos().
Returns the global y position of the mouse pointer at the time of the event.
See also globalX() and globalPos().
Returns the position of the mouse pointer relative to the widget that received the event.
See also x(), y(), and globalPos().
Returns the reason for this context event.
Returns the x position of the mouse pointer, relative to the widget that received the event.
Returns the y position of the mouse pointer, relative to the widget that received the event.
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. | Qt 4.1 | |
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD. | ||
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com