| 45 | } |
| 46 | |
| 47 | bool |
| 48 | MouseTracker::configure (const std::string &name, const std::string &value) |
| 49 | { |
| 50 | if (name == cfg_crosshair_cursor_color) { |
| 51 | |
| 52 | tl::Color color; |
| 53 | lay::ColorConverter ().from_string (value, color); |
| 54 | |
| 55 | // Change the color |
| 56 | if (lay::test_and_set (m_cursor_color, color)) { |
| 57 | mp_markers.clear (); |
| 58 | } |
| 59 | |
| 60 | } else if (name == cfg_crosshair_cursor_line_style) { |
| 61 | |
| 62 | int dp = 0; |
| 63 | tl::from_string (value, dp); |
| 64 | |
| 65 | // Change the vertex_size |
| 66 | if (lay::test_and_set (m_cursor_line_style, dp)) { |
| 67 | mp_markers.clear (); |
| 68 | } |
| 69 | |
| 70 | } else if (name == cfg_crosshair_cursor_enabled) { |
| 71 | |
| 72 | bool f = m_cursor_enabled; |
| 73 | tl::from_string (value, f); |
| 74 | if (f != m_cursor_enabled) { |
| 75 | m_cursor_enabled = f; |
| 76 | mp_markers.clear (); |
| 77 | } |
| 78 | |
| 79 | } |
| 80 | |
| 81 | return false; // not taken |
| 82 | } |
| 83 | |
| 84 | bool |
| 85 | MouseTracker::mouse_move_event (const db::DPoint &p, unsigned int /*buttons*/, bool prio) |
nothing calls this directly
no test coverage detected