MCPcopy Create free account
hub / github.com/LibreSprite/LibreSprite / onCanCopy

Method onCanCopy

src/app/ui/document_view.cpp:444–455  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

442}
443
444bool DocumentView::onCanCopy(Context* ctx)
445{
446 if (ctx->checkFlags(ContextFlags::ActiveDocumentIsWritable |
447 ContextFlags::ActiveLayerIsVisible |
448 ContextFlags::HasVisibleMask |
449 ContextFlags::HasActiveImage))
450 return true;
451 else if (m_editor->isMovingPixels())
452 return true;
453 else
454 return false;
455}
456
457bool DocumentView::onCanPaste(Context* ctx)
458{

Callers

nothing calls this directly

Calls 2

checkFlagsMethod · 0.80
isMovingPixelsMethod · 0.80

Tested by

no test coverage detected