Compare commits

...

4 Commits

Author SHA1 Message Date
copilot-swe-agent[bot]
ecc09927f7 Remove non-functional test file per code review feedback
Co-authored-by: yeelam-gordon <73506701+yeelam-gordon@users.noreply.github.com>
2026-01-31 03:23:47 +00:00
copilot-swe-agent[bot]
a67f1d6258 Add documentation test for UI hiding fix in ZoomWindowHelper
Co-authored-by: yeelam-gordon <73506701+yeelam-gordon@users.noreply.github.com>
2025-08-29 06:57:10 +00:00
copilot-swe-agent[bot]
52ecda417c Fix Color Picker UI visibility during zoom by temporarily hiding main window
Co-authored-by: yeelam-gordon <73506701+yeelam-gordon@users.noreply.github.com>
2025-08-29 06:53:39 +00:00
copilot-swe-agent[bot]
1976fbc3d5 Initial plan 2025-08-29 06:49:01 +00:00

View File

@@ -82,7 +82,19 @@ namespace ColorPicker.Helpers
var x = (int)point.X - (BaseZoomImageSize / 2);
var y = (int)point.Y - (BaseZoomImageSize / 2);
_graphics.CopyFromScreen(x, y, 0, 0, _bmp.Size, CopyPixelOperation.SourceCopy);
// Temporarily hide the color picker UI to avoid capturing it in the zoom
var originalOpacity = System.Windows.Application.Current.MainWindow.Opacity;
System.Windows.Application.Current.MainWindow.Opacity = 0;
try
{
_graphics.CopyFromScreen(x, y, 0, 0, _bmp.Size, CopyPixelOperation.SourceCopy);
}
finally
{
// Restore the original opacity
System.Windows.Application.Current.MainWindow.Opacity = originalOpacity;
}
_zoomViewModel.ZoomArea = BitmapToImageSource(_bmp);
}