Removed unneeded scroll code. Fixed a potential null-pointer bug in CaptureRectangle. Fixed a bug with GDI captures being black by counting the pixels and if there is a difference taking the screen shot instead.

git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@2238 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
RKrom 2012-11-05 16:05:07 +00:00
parent fd46837c8d
commit 35b16e8fd9
4 changed files with 48 additions and 110 deletions

View file

@ -587,7 +587,9 @@ namespace GreenshotPlugin.Core {
}
capture.Image = CaptureRectangle(captureBounds);
capture.Location = captureBounds.Location;
((Bitmap)capture.Image).SetResolution(capture.CaptureDetails.DpiX, capture.CaptureDetails.DpiY);
if (capture.CaptureDetails != null) {
((Bitmap)capture.Image).SetResolution(capture.CaptureDetails.DpiX, capture.CaptureDetails.DpiY);
}
if (capture.Image == null) {
return null;
}