node-mac-recorder 2.10.38 → 2.10.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/window_selector.mm +34 -15
package/package.json
CHANGED
package/src/window_selector.mm
CHANGED
|
@@ -224,7 +224,20 @@ void updateScreenOverlays();
|
|
|
224
224
|
self.isHovered = YES;
|
|
225
225
|
[[NSCursor pointingHandCursor] set];
|
|
226
226
|
|
|
227
|
-
|
|
227
|
+
// Brighten background on hover
|
|
228
|
+
if (self.layer.backgroundColor) {
|
|
229
|
+
CGFloat red, green, blue, alpha;
|
|
230
|
+
NSColor *currentColor = [NSColor colorWithCGColor:self.layer.backgroundColor];
|
|
231
|
+
[currentColor getRed:&red green:&green blue:&blue alpha:&alpha];
|
|
232
|
+
|
|
233
|
+
// Increase brightness by 20%
|
|
234
|
+
red = MIN(1.0, red * 1.2);
|
|
235
|
+
green = MIN(1.0, green * 1.2);
|
|
236
|
+
blue = MIN(1.0, blue * 1.2);
|
|
237
|
+
|
|
238
|
+
NSColor *brighterColor = [NSColor colorWithRed:red green:green blue:blue alpha:alpha];
|
|
239
|
+
self.layer.backgroundColor = [brighterColor CGColor];
|
|
240
|
+
}
|
|
228
241
|
}
|
|
229
242
|
|
|
230
243
|
- (void)mouseExited:(NSEvent *)event {
|
|
@@ -316,7 +329,7 @@ void updateScreenOverlays();
|
|
|
316
329
|
// Semi-transparent black background for screen overlay (same as window overlay)
|
|
317
330
|
self.layer.backgroundColor = [[NSColor colorWithRed:0.0 green:0.0 blue:0.0 alpha:0.3] CGColor];
|
|
318
331
|
// Ensure no borders or decorations
|
|
319
|
-
self.layer.borderWidth =
|
|
332
|
+
self.layer.borderWidth = 1.0;
|
|
320
333
|
self.layer.cornerRadius = 8.0;
|
|
321
334
|
self.layer.masksToBounds = YES;
|
|
322
335
|
self.layer.shadowOpacity = 0.0;
|
|
@@ -374,11 +387,11 @@ void updateScreenOverlays();
|
|
|
374
387
|
self = [super initWithFrame:frameRect];
|
|
375
388
|
if (self) {
|
|
376
389
|
self.wantsLayer = YES;
|
|
377
|
-
// Semi-transparent background for screen overlay (same as window overlay)
|
|
378
|
-
self.layer.backgroundColor = [[NSColor colorWithRed:0.
|
|
390
|
+
// Semi-transparent blue background for screen overlay (same as window overlay blue tint)
|
|
391
|
+
self.layer.backgroundColor = [[NSColor colorWithRed:0.27 green:0.0 blue:0.77 alpha:0.18] CGColor];
|
|
379
392
|
// Blue border for screen selection (same as window highlight)
|
|
380
|
-
self.layer.borderWidth =
|
|
381
|
-
self.layer.borderColor = [[NSColor colorWithRed:0.27 green:0.0 blue:0.77 alpha:0.
|
|
393
|
+
self.layer.borderWidth = 1.0;
|
|
394
|
+
self.layer.borderColor = [[NSColor colorWithRed:0.27 green:0.0 blue:0.77 alpha:0.9] CGColor];
|
|
382
395
|
self.layer.cornerRadius = 8.0;
|
|
383
396
|
self.layer.masksToBounds = YES;
|
|
384
397
|
self.layer.shadowOpacity = 0.0;
|
|
@@ -394,13 +407,13 @@ void updateScreenOverlays();
|
|
|
394
407
|
|
|
395
408
|
if (!self.screenInfo) return;
|
|
396
409
|
|
|
397
|
-
// Background with transparency -
|
|
410
|
+
// Background with transparency - blue tone (same as window highlight)
|
|
398
411
|
if (self.isActiveScreen) {
|
|
399
|
-
// Active screen:
|
|
400
|
-
[[NSColor colorWithRed:0.
|
|
412
|
+
// Active screen: locked state blue (#3d00b047)
|
|
413
|
+
[[NSColor colorWithRed:0.24 green:0.0 blue:0.69 alpha:0.278] setFill];
|
|
401
414
|
} else {
|
|
402
|
-
// Inactive screen:
|
|
403
|
-
[[NSColor colorWithRed:0.
|
|
415
|
+
// Inactive screen: normal state blue (#4400c52e)
|
|
416
|
+
[[NSColor colorWithRed:0.27 green:0.0 blue:0.77 alpha:0.18] setFill];
|
|
404
417
|
}
|
|
405
418
|
NSRectFill(self.bounds);
|
|
406
419
|
|
|
@@ -410,9 +423,15 @@ void updateScreenOverlays();
|
|
|
410
423
|
- (void)setIsActiveScreen:(BOOL)isActive {
|
|
411
424
|
_isActiveScreen = isActive;
|
|
412
425
|
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
426
|
+
if (isActive) {
|
|
427
|
+
// Active screen: locked state blue border (same as window highlight locked)
|
|
428
|
+
self.layer.borderColor = [[NSColor colorWithRed:0.24 green:0.0 blue:0.69 alpha:0.95] CGColor];
|
|
429
|
+
self.layer.backgroundColor = [[NSColor colorWithRed:0.24 green:0.0 blue:0.69 alpha:0.278] CGColor];
|
|
430
|
+
} else {
|
|
431
|
+
// Inactive screen: normal state blue border (same as window highlight normal)
|
|
432
|
+
self.layer.borderColor = [[NSColor colorWithRed:0.27 green:0.0 blue:0.77 alpha:0.9] CGColor];
|
|
433
|
+
self.layer.backgroundColor = [[NSColor colorWithRed:0.27 green:0.0 blue:0.77 alpha:0.18] CGColor];
|
|
434
|
+
}
|
|
416
435
|
}
|
|
417
436
|
|
|
418
437
|
@end
|
|
@@ -887,7 +906,7 @@ void updateOverlay() {
|
|
|
887
906
|
[appIconView.layer setBackgroundColor:[[NSColor colorWithRed:0.2 green:0.2 blue:0.2 alpha:0.3] CGColor]]; // Debug background
|
|
888
907
|
|
|
889
908
|
// Force no borders on app icon view
|
|
890
|
-
appIconView.layer.borderWidth =
|
|
909
|
+
appIconView.layer.borderWidth = 1.0;
|
|
891
910
|
appIconView.layer.borderColor = [[NSColor clearColor] CGColor];
|
|
892
911
|
appIconView.layer.shadowOpacity = 0.0;
|
|
893
912
|
appIconView.layer.shadowRadius = 0.0;
|