#include "Mouse.h"
#include "../base/DebugRouter.h"
#include "../gfxsetup/GFXSetup.h"
#include <algorithm>
Namespaces | |
namespace | GFX_INTERNAL |
namespace | INPUT_INTERNAL |
namespace | INPUT |
namespace | INPUT::MOUSE |
Functions | |
const std::string & | INPUT::MOUSE::GetFriendlyName (uint8 button) |
Returns the friendly name for a mouse button. | |
bool | INPUT::MOUSE::IsButtonDown (uint8 button) |
Returns whether the specified mouse button is currently down. | |
const std::vector< uint8 > & | INPUT::MOUSE::GetCurrentlyPressedButtons () |
Returns a list of mouse buttons that are currently pressed down. | |
const std::vector< uint8 > & | INPUT::MOUSE::GetNewlyPressedButtons () |
Returns a list of mouse buttons that were newly pressed within the last frame. | |
int | INPUT::MOUSE::GetWheelDirection () |
Returns the most recent scroll direction of the mouse wheel, counted in number of wheel ticks. The value can be negative or positive, or 0 if no movement occured. | |
MouseScaledPosition | INPUT::MOUSE::GetScaledPosition () |
Returns the location of the mouse within the window, where X and Y are a value between 0 and 1. This function is only usable in absolute mode, and always returns 0s in relative mode. | |
const std::vector < MouseScaledPosition > & | INPUT::MOUSE::GetScaledTrail () |
Same as GetScaledPosition(), except this returns a list of all known locations that the server passed over since the last frame. | |
MousePixelPosition | INPUT::MOUSE::GetPixelPosition () |
Returns the location of the mouse within the window, measured in pixels. In absolute mode this returns the location of the cursor relative to the origin. In relative mode this returns the number of pixels in each direction that the mouse moved since last frame. | |
const std::vector < MousePixelPosition > & | INPUT::MOUSE::GetPixelTrail () |
Same as GetPixelPosition, except this returns a list of all known locations that the server passed over since the last frame. This function is only valid in absolute mode, and returns an empty list in relative mode. |
Mouse input platform-common code.