Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix screen capture for Mac. #242

Merged
merged 14 commits into from
Oct 16, 2016
Prev Previous commit
Next Next commit
Space before comment.
  • Loading branch information
octalmage committed May 15, 2016
commit e2ff6cd574036660418ced7c1f1d692bc42eb87d
4 changes: 2 additions & 2 deletions src/robotjs.cc
Original file line number Diff line number Diff line change
Expand Up @@ -793,15 +793,15 @@ NAN_METHOD(saveBitmap)
MMBitmapRef bitmap;
MMImageType type = kBMPImageType;

//Get our image object from JavaScript.
// Get our image object from JavaScript.
BMP img = buildBMP(Nan::To<v8::Object>(info[0]).ToLocalChecked());

char *path;
Nan::Utf8String string(info[1]);

path = *string;

//Create the bitmap.
// Create the bitmap.
bitmap = createMMBitmap(img.image, img.width, img.height, img.byteWidth, img.bitsPerPixel, img.bytesPerPixel);

if (saveMMBitmapToFile(bitmap, path, type) != 0) {
Expand Down