Changeset View
Changeset View
Standalone View
Standalone View
libs/ui/tool/kis_tool_freehand.cc
Show First 20 Lines • Show All 182 Lines • ▼ Show 20 Line(s) | 181 | if (canvas2) { | |||
---|---|---|---|---|---|
183 | m_helper->setCanvasRotation(canvas2->rotationAngle()); | 183 | m_helper->setCanvasRotation(canvas2->rotationAngle()); | ||
184 | } | 184 | } | ||
185 | m_helper->paintEvent(event); | 185 | m_helper->paintEvent(event); | ||
186 | } | 186 | } | ||
187 | 187 | | |||
188 | void KisToolFreehand::endStroke() | 188 | void KisToolFreehand::endStroke() | ||
189 | { | 189 | { | ||
190 | m_helper->endPaint(); | 190 | m_helper->endPaint(); | ||
191 | bool paintOpIgnoredEvent = currentPaintOpPreset()->settings()->mouseReleaseEvent(); | ||||
192 | Q_UNUSED(paintOpIgnoredEvent); | ||||
191 | } | 193 | } | ||
192 | 194 | | |||
193 | bool KisToolFreehand::primaryActionSupportsHiResEvents() const | 195 | bool KisToolFreehand::primaryActionSupportsHiResEvents() const | ||
194 | { | 196 | { | ||
195 | return true; | 197 | return true; | ||
196 | } | 198 | } | ||
197 | 199 | | |||
198 | void KisToolFreehand::beginPrimaryAction(KoPointerEvent *event) | 200 | void KisToolFreehand::beginPrimaryAction(KoPointerEvent *event) | ||
▲ Show 20 Lines • Show All 81 Lines • ▼ Show 20 Line(s) | 281 | bool paintOpIgnoredEvent = currentPaintOpPreset()->settings()-> | |||
280 | mousePressEvent(KisPaintInformation(convertToPixelCoord(event->point), | 282 | mousePressEvent(KisPaintInformation(convertToPixelCoord(event->point), | ||
281 | m_infoBuilder->pressureToCurve(event->pressure()), | 283 | m_infoBuilder->pressureToCurve(event->pressure()), | ||
282 | event->xTilt(), event->yTilt(), | 284 | event->xTilt(), event->yTilt(), | ||
283 | event->rotation(), | 285 | event->rotation(), | ||
284 | event->tangentialPressure(), | 286 | event->tangentialPressure(), | ||
285 | perspective, 0, 0), | 287 | perspective, 0, 0), | ||
286 | event->modifiers(), | 288 | event->modifiers(), | ||
287 | currentNode()); | 289 | currentNode()); | ||
290 | // DuplicateOP during the picking of new source point (origin) | ||||
291 | // is the only paintop that returns "false" here | ||||
288 | return !paintOpIgnoredEvent; | 292 | return !paintOpIgnoredEvent; | ||
289 | } | 293 | } | ||
290 | 294 | | |||
291 | void KisToolFreehand::activateAlternateAction(AlternateAction action) | 295 | void KisToolFreehand::activateAlternateAction(AlternateAction action) | ||
292 | { | 296 | { | ||
293 | if (action != ChangeSize) { | 297 | if (action != ChangeSize) { | ||
294 | KisToolPaint::activateAlternateAction(action); | 298 | KisToolPaint::activateAlternateAction(action); | ||
295 | return; | 299 | return; | ||
▲ Show 20 Lines • Show All 163 Lines • Show Last 20 Lines |