mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-15 19:27:56 +01:00
[CPP] Fix MTC build on the latest msvc (#21926)
This commit is contained in:
@@ -54,7 +54,7 @@ namespace
|
|||||||
ClipCursor(nullptr);
|
ClipCursor(nullptr);
|
||||||
|
|
||||||
toolState->commonState->overlayBoxText.Read([](const OverlayBoxText& text) {
|
toolState->commonState->overlayBoxText.Read([](const OverlayBoxText& text) {
|
||||||
SetClipBoardToText(text.buffer);
|
SetClipBoardToText(text.buffer.data());
|
||||||
});
|
});
|
||||||
|
|
||||||
if (const bool shiftPress = GetKeyState(VK_SHIFT) & 0x8000; shiftPress && toolState->perScreen[window].currentBounds)
|
if (const bool shiftPress = GetKeyState(VK_SHIFT) & 0x8000; shiftPress && toolState->perScreen[window].currentBounds)
|
||||||
|
|||||||
@@ -93,7 +93,7 @@ LRESULT CALLBACK MeasureToolWndProc(HWND window, UINT message, WPARAM wparam, LP
|
|||||||
if (auto state = GetWindowParam<Serialized<MeasureToolState>*>(window))
|
if (auto state = GetWindowParam<Serialized<MeasureToolState>*>(window))
|
||||||
{
|
{
|
||||||
state->Read([](const MeasureToolState& s) { s.commonState->overlayBoxText.Read([](const OverlayBoxText& text) {
|
state->Read([](const MeasureToolState& s) { s.commonState->overlayBoxText.Read([](const OverlayBoxText& text) {
|
||||||
SetClipBoardToText(text.buffer);
|
SetClipBoardToText(text.buffer.data());
|
||||||
}); });
|
}); });
|
||||||
}
|
}
|
||||||
PostMessageW(window, WM_CLOSE, {}, {});
|
PostMessageW(window, WM_CLOSE, {}, {});
|
||||||
|
|||||||
Reference in New Issue
Block a user