Wt::WMouseEvent Class Reference
[Signal/slot system]

A class providing details for a mouse event. More...

#include <Wt/WEvent>

List of all members.

Public Types

enum  Button { LeftButton, MiddleButton, RightButton }
 Enumeration for the mouse button. More...

Public Member Functions

 WMouseEvent ()
 Default constructor.
Button button () const
 Get the button.
int modifiers () const
 Returns keyboard modifiers.
Coordinates document () const
 Get the mouse position relative to the document.
Coordinates window () const
 Get the mouse position relative to the window.
Coordinates screen () const
 Get the mouse position relative to the screen.
Coordinates widget () const
 Get the mouse position relative to the widget.
Coordinates dragDelta () const
 Get the distance over which the mouse has been dragged.
bool altKey () const
 Returns whether the alt key is pressed (deprecated).
bool metaKey () const
 Returns whether the meta key is pressed (deprecated).
bool ctrlKey () const
 Returns whether the control key is pressed (deprecated).
bool shiftKey () const
 Returns whether the shift key is pressed (deprecated).

Classes

struct  Coordinates
 A mouse coordinate. More...


Detailed Description

A class providing details for a mouse event.

See also:
WInteractWidget::clicked

Member Enumeration Documentation

Enumeration for the mouse button.

Enumerator:
LeftButton  Left button.
MiddleButton  Middle button.
RightButton  Right button.


Member Function Documentation

int Wt::WMouseEvent::modifiers (  )  const [inline]

Returns keyboard modifiers.

The result is a logical OR of KeyboardModifier flags.

Coordinates Wt::WMouseEvent::window (  )  const [inline]

Get the mouse position relative to the window.

This differs from documentX() only through scrolling through the document.

Coordinates Wt::WMouseEvent::dragDelta (  )  const [inline]

Get the distance over which the mouse has been dragged.

This is only defined for a mouseWentUp event.

bool Wt::WMouseEvent::altKey (  )  const [inline]

Returns whether the alt key is pressed (deprecated).

Deprecated:
Use modifiers() instead.

bool Wt::WMouseEvent::metaKey (  )  const [inline]

Returns whether the meta key is pressed (deprecated).

Deprecated:
Use modifiers() instead.

bool Wt::WMouseEvent::ctrlKey (  )  const [inline]

Returns whether the control key is pressed (deprecated).

Deprecated:
Use modifiers() instead.

bool Wt::WMouseEvent::shiftKey (  )  const [inline]

Returns whether the shift key is pressed (deprecated).

Deprecated:
Use modifiers() instead.


Generated on Fri Apr 24 16:25:59 2009 for Wt by doxygen 1.5.6