| 37 | |
| 38 | |
| 39 | void SvgSwitch::onDragStart(const DragStartEvent& e) { |
| 40 | Switch::onDragStart(e); |
| 41 | if (e.button != GLFW_MOUSE_BUTTON_LEFT) |
| 42 | return; |
| 43 | |
| 44 | // Set down frame if latch |
| 45 | if (latch) { |
| 46 | if (frames.size() >= 2) { |
| 47 | sw->setSvg(frames[1]); |
| 48 | fb->setDirty(); |
| 49 | } |
| 50 | } |
| 51 | } |
| 52 | |
| 53 | |
| 54 | void SvgSwitch::onDragEnd(const DragEndEvent& e) { |