cleanup: Don't shadow variables
Having variables that share the same name in overlapping scopes is confusing and error-prone, and is best avoided. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/805
This commit is contained in:

committed by
Georges Basile Stavracas Neto

parent
2e4e2500dd
commit
682bd7e97c
@ -230,7 +230,7 @@ var ScreenshotService = class {
|
||||
SelectAreaAsync(params, invocation) {
|
||||
let selectArea = new SelectArea();
|
||||
selectArea.show();
|
||||
selectArea.connect('finished', (selectArea, areaRectangle) => {
|
||||
selectArea.connect('finished', (o, areaRectangle) => {
|
||||
if (areaRectangle) {
|
||||
let retRectangle = this._unscaleArea(areaRectangle.x, areaRectangle.y,
|
||||
areaRectangle.width, areaRectangle.height);
|
||||
@ -260,7 +260,7 @@ var ScreenshotService = class {
|
||||
PickColorAsync(params, invocation) {
|
||||
let pickPixel = new PickPixel();
|
||||
pickPixel.show();
|
||||
pickPixel.connect('finished', (pickPixel, coords) => {
|
||||
pickPixel.connect('finished', (obj, coords) => {
|
||||
if (coords) {
|
||||
let screenshot = this._createScreenshot(invocation, false);
|
||||
if (!screenshot)
|
||||
|
Reference in New Issue
Block a user