This repository was archived by the owner on Feb 25, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 5 files changed +449
-1
lines changed
shell/platform/darwin/macos Expand file tree Collapse file tree 5 files changed +449
-1
lines changed Original file line number Diff line number Diff line change @@ -2672,6 +2672,7 @@ ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMou
26722672ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMouseCursorPlugin.mm + ../../../flutter/LICENSE
26732673ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMutatorView.h + ../../../flutter/LICENSE
26742674ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMutatorView.mm + ../../../flutter/LICENSE
2675+ ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMutatorViewTest.mm + ../../../flutter/LICENSE
26752676ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterPlatformNodeDelegateMac.h + ../../../flutter/LICENSE
26762677ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterPlatformNodeDelegateMac.mm + ../../../flutter/LICENSE
26772678ORIGIN: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterPlatformNodeDelegateMacTest.mm + ../../../flutter/LICENSE
@@ -5168,6 +5169,7 @@ FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMouse
51685169FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMouseCursorPlugin.mm
51695170FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMutatorView.h
51705171FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMutatorView.mm
5172+ FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterMutatorViewTest.mm
51715173FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterPlatformNodeDelegateMac.h
51725174FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterPlatformNodeDelegateMac.mm
51735175FILE: ../../../flutter/shell/platform/darwin/macos/framework/Source/FlutterPlatformNodeDelegateMacTest.mm
Original file line number Diff line number Diff line change @@ -174,6 +174,7 @@ executable("flutter_desktop_darwin_unittests") {
174174 " framework/Source/FlutterEngineTestUtils.mm" ,
175175 " framework/Source/FlutterKeyboardManagerTest.mm" ,
176176 " framework/Source/FlutterMenuPluginTest.mm" ,
177+ " framework/Source/FlutterMutatorViewTest.mm" ,
177178 " framework/Source/FlutterPlatformNodeDelegateMacTest.mm" ,
178179 " framework/Source/FlutterPlatformViewControllerTest.mm" ,
179180 " framework/Source/FlutterRendererTest.mm" ,
Original file line number Diff line number Diff line change 2222- (void )applyFlutterLayer : (nonnull const FlutterLayer*)layer ;
2323
2424@end
25+
26+ @interface FlutterMutatorView (Private)
27+
28+ @property (readonly , nonatomic , nonnull ) NSMutableArray <NSView*>* pathClipViews;
29+ @property (readonly , nonatomic , nullable ) NSView * platformViewContainer;
30+
31+ @end
Original file line number Diff line number Diff line change @@ -194,6 +194,14 @@ - (NSView*)platformView {
194194 return _platformView;
195195}
196196
197+ - (NSMutableArray *)pathClipViews {
198+ return _pathClipViews;
199+ }
200+
201+ - (NSView *)platformViewContainer {
202+ return _platformViewContainer;
203+ }
204+
197205- (instancetype )initWithPlatformView : (NSView *)platformView {
198206 if (self = [super initWithFrame: NSZeroRect ]) {
199207 _platformView = platformView;
@@ -215,7 +223,7 @@ - (BOOL)isFlipped {
215223// / If clipping to path is needed, CAShapeLayer(s) will be used as mask.
216224// / Clipping to round rect only clips to path if round corners are intersected.
217225- (void )applyFlutterLayer : (const FlutterLayer*)layer {
218- CGFloat scale = self.superview . layer .contentsScale ;
226+ CGFloat scale = self.superview != nil ? self. superview . layer .contentsScale : 1.0 ;
219227
220228 // Initial transform to compensate for scale factor. This is needed because all
221229 // cocoa coordinates are logical but Flutter will send the physical to logical
You can’t perform that action at this time.
0 commit comments