flutter-plugins icon indicating copy to clipboard operation
flutter-plugins copied to clipboard

[desktop_webview_window] Webview doesn't work on macOS

Open treeplate opened this issue 9 months ago • 2 comments

When I try to launch a webview window, it instead launches a copy of the main app, and when that tries to launch a webview window, it crashes.

Reproduce Steps

lib/main.dart:

import 'package:flutter/material.dart';
import 'package:desktop_webview_window/desktop_webview_window.dart';

void main(List<String> arguments) {
  runApp(
    MaterialApp(
      home: Scaffold(
        body: OutlinedButton(
          child: FlutterLogo(),
          onPressed: () {
            WebviewWindow.create().then((webview) {
              webview.launch('example.com');
            });
          },
        ),
      ),
    ),
  );
}

Run the app, press the button. Then, press the button on the new window that launched.

what it looks like window on window

Version (please complete the following information):

  • Flutter Version: 3.22.0-31.0.pre.3
  • OS: macOS 14.4.1
  • plugin: desktop_webview_window

treeplate avatar May 10 '24 21:05 treeplate