Add deprecated comment to scaleFactor parameter

This commit is contained in:
Kevin Sawicki 2016-12-14 10:18:01 -08:00
parent 3b259b4243
commit 8680a08a8d
2 changed files with 10 additions and 2 deletions

View file

@ -410,13 +410,14 @@ mate::Handle<NativeImage> NativeImage::CreateFromBuffer(
int height = 0;
double scale_factor = 1.;
args->GetNext(&scale_factor);
mate::Dictionary options;
if (args->GetNext(&options)) {
options.Get("width", &width);
options.Get("height", &height);
options.Get("scaleFactor", &scale_factor);
} else {
// TODO(kevinsawicki): Remove in 2.0, deprecate before then with warnings
args->GetNext(&scale_factor);
}
gfx::ImageSkia image_skia;