diff --git a/shell/platform/darwin/ios/ios_surface.h b/shell/platform/darwin/ios/ios_surface.h index d5dfca5526c51..a01f9f15caeed 100644 --- a/shell/platform/darwin/ios/ios_surface.h +++ b/shell/platform/darwin/ios/ios_surface.h @@ -34,8 +34,6 @@ class IOSSurface : public ExternalViewEmbedder { std::shared_ptr GetContext() const; - ExternalViewEmbedder* GetExternalViewEmbedderIfEnabled(); - virtual bool IsValid() const = 0; virtual void UpdateStorageSizeIfNecessary() = 0; diff --git a/shell/platform/darwin/ios/ios_surface.mm b/shell/platform/darwin/ios/ios_surface.mm index 30327582a2599..65fccb052e78b 100644 --- a/shell/platform/darwin/ios/ios_surface.mm +++ b/shell/platform/darwin/ios/ios_surface.mm @@ -13,15 +13,6 @@ namespace flutter { -// The name of the Info.plist flag to enable the embedded iOS views preview. -constexpr const char* kEmbeddedViewsPreview = "io.flutter.embedded_views_preview"; - -bool IsIosEmbeddedViewsPreviewEnabled() { - static bool preview_enabled = - [[[NSBundle mainBundle] objectForInfoDictionaryKey:@(kEmbeddedViewsPreview)] boolValue]; - return preview_enabled; -} - std::unique_ptr IOSSurface::Create( std::shared_ptr context, fml::scoped_nsobject layer, @@ -75,14 +66,6 @@ bool IsIosEmbeddedViewsPreviewEnabled() { return nullptr; } -ExternalViewEmbedder* IOSSurface::GetExternalViewEmbedderIfEnabled() { - if (IsIosEmbeddedViewsPreviewEnabled()) { - return this; - } else { - return nullptr; - } -} - // |ExternalViewEmbedder| void IOSSurface::CancelFrame() { TRACE_EVENT0("flutter", "IOSSurface::CancelFrame"); diff --git a/shell/platform/darwin/ios/ios_surface_gl.mm b/shell/platform/darwin/ios/ios_surface_gl.mm index 9da8d9ea50088..05d2d313566fe 100644 --- a/shell/platform/darwin/ios/ios_surface_gl.mm +++ b/shell/platform/darwin/ios/ios_surface_gl.mm @@ -84,7 +84,7 @@ // |GPUSurfaceGLDelegate| ExternalViewEmbedder* IOSSurfaceGL::GetExternalViewEmbedder() { - return GetExternalViewEmbedderIfEnabled(); + return this; } } // namespace flutter diff --git a/shell/platform/darwin/ios/ios_surface_metal.mm b/shell/platform/darwin/ios/ios_surface_metal.mm index 60afa6fd69775..df0d2739cfce7 100644 --- a/shell/platform/darwin/ios/ios_surface_metal.mm +++ b/shell/platform/darwin/ios/ios_surface_metal.mm @@ -55,7 +55,7 @@ // |GPUSurfaceDelegate| ExternalViewEmbedder* IOSSurfaceMetal::GetExternalViewEmbedder() { - return GetExternalViewEmbedderIfEnabled(); + return this; } } // namespace flutter diff --git a/shell/platform/darwin/ios/ios_surface_software.mm b/shell/platform/darwin/ios/ios_surface_software.mm index a68e0509f8ab4..03e85aec611f7 100644 --- a/shell/platform/darwin/ios/ios_surface_software.mm +++ b/shell/platform/darwin/ios/ios_surface_software.mm @@ -124,7 +124,7 @@ // |GPUSurfaceSoftwareDelegate| ExternalViewEmbedder* IOSSurfaceSoftware::GetExternalViewEmbedder() { - return GetExternalViewEmbedderIfEnabled(); + return this; } } // namespace flutter diff --git a/testing/scenario_app/ios/Scenarios/Scenarios/Info.plist b/testing/scenario_app/ios/Scenarios/Scenarios/Info.plist index 032a9620fa3f2..bc23fd5445d4d 100644 --- a/testing/scenario_app/ios/Scenarios/Scenarios/Info.plist +++ b/testing/scenario_app/ios/Scenarios/Scenarios/Info.plist @@ -41,7 +41,5 @@ UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight - io.flutter.embedded_views_preview -