Public Member Functions

editor::mouse_action_select Class Reference

Select (and deselect) action, by brush or "magic wand" (via keyboard modifier). More...

#include <mouse_action.hpp>

Inheritance diagram for editor::mouse_action_select:
Inheritance graph
[legend]
Collaboration diagram for editor::mouse_action_select:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 mouse_action_select (const brush *const *const brush, const CKey &key, empty_palette &palette)
std::set< map_locationaffected_hexes (editor_display &disp, const map_location &hex)
 Overridden to allow special behaviour based on modifier keys.
editor_actionkey_event (editor_display &disp, const SDL_Event &e)
 Force a fake "move" event to update brush overlay on key event.
editor_actionclick_perform_left (editor_display &disp, const std::set< map_location > &hexes)
 Left click/drag selects.
editor_actionclick_perform_right (editor_display &disp, const std::set< map_location > &hexes)
 Right click/drag deselects.
virtual void set_mouse_overlay (editor_display &disp)
 Set the mouse overlay for this action.

Detailed Description

Select (and deselect) action, by brush or "magic wand" (via keyboard modifier).

Definition at line 289 of file mouse_action.hpp.


Constructor & Destructor Documentation

editor::mouse_action_select::mouse_action_select ( const brush *const *const   brush,
const CKey key,
empty_palette palette 
) [inline]

Definition at line 292 of file mouse_action.hpp.


Member Function Documentation

std::set< map_location > editor::mouse_action_select::affected_hexes ( editor_display disp,
const map_location hex 
) [virtual]

Overridden to allow special behaviour based on modifier keys.

Reimplemented from editor::brush_drag_mouse_action.

Definition at line 299 of file mouse_action.cpp.

References editor::editor_map::get_contiguous_terrain_tiles(), editor::mouse_action::has_shift_modifier(), and editor::editor_display::map().

Here is the call graph for this function:

editor_action * editor::mouse_action_select::click_perform_left ( editor_display disp,
const std::set< map_location > &  hexes 
) [virtual]

Left click/drag selects.

Implements editor::brush_drag_mouse_action.

Definition at line 317 of file mouse_action.cpp.

editor_action * editor::mouse_action_select::click_perform_right ( editor_display disp,
const std::set< map_location > &  hexes 
) [virtual]

Right click/drag deselects.

Implements editor::brush_drag_mouse_action.

Definition at line 323 of file mouse_action.cpp.

editor_action * editor::mouse_action_select::key_event ( editor_display disp,
const SDL_Event &  e 
) [virtual]

Force a fake "move" event to update brush overlay on key event.

Reimplemented from editor::mouse_action.

Definition at line 309 of file mouse_action.cpp.

void editor::mouse_action_select::set_mouse_overlay ( editor_display disp  )  [virtual]

Set the mouse overlay for this action.

Defaults to an empty overlay.

Reimplemented from editor::mouse_action.

Definition at line 329 of file mouse_action.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Thu May 24 2012 01:19:32 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs