[MSPAINT] Make selection window-less (#5208)

- Delete selection.cpp and selection.h and selectionWindow.
- Extend ColorKeyedMaskBlt function.
- Implement selection resizing.
CORE-18867
This commit is contained in:
Katayama Hirofumi MZ 2023-04-01 22:01:04 +09:00 committed by GitHub
parent 3f5bcf5775
commit aac89519ec
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 702 additions and 829 deletions

View file

@ -150,14 +150,25 @@ LRESULT CCanvasWindow::OnLButtonDown(UINT nMsg, WPARAM wParam, LPARAM lParam, BO
if (hit == HIT_NONE || hit == HIT_BORDER)
{
if (toolsModel.GetActiveTool() == TOOL_BEZIER ||
toolsModel.GetActiveTool() == TOOL_SHAPE)
switch (toolsModel.GetActiveTool())
{
if (ToolBase::pointSP != 0)
{
toolsModel.OnCancelDraw();
case TOOL_BEZIER:
case TOOL_SHAPE:
if (ToolBase::pointSP != 0)
{
toolsModel.OnCancelDraw();
imageArea.Invalidate();
}
break;
case TOOL_FREESEL:
case TOOL_RECTSEL:
toolsModel.OnFinishDraw();
imageArea.Invalidate();
}
break;
default:
break;
}
toolsModel.resetTool(); // resets the point-buffer of the polygon and bezier functions