-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Description
Use Flutter's DEV branch and win32 plug-in.In windows desktop projects, the window loses its response when the MoveWindow function of win32 is called directly from the Flutter interface. It is suspected WM_SIZE the modification of the sub-window in the message.
The 1.26.0-12.0.pre version of flutter does not have this problem.
After the flutter is updated to the latest version (DEV or 1.27.0-4.0pre), the program stops responding after modifying the window size through MoveWindow or SetWindowPos interface.
I raised this issue in the win32 plug-in project, and it has been agreed that this is not a win32 plug-in issue.
(halildurmus/win32#157)
I found a solution. By modifying the (windows\runner\win32_window.cpp) file, create a custom message that delays the code WM_SIZE the modified sub-window.
(#76973)
This is the test project I wrote, please note that the latest submission contains the solution.
(https://github.com/tilongzs/win32_movewindow_test)
Flutter crash report.
Please report a bug at https://github.com/flutter/flutter/issues.
command
flutter run --verbose
exception
RPCError: getIsolate: (112) Service has disappeared
flutter doctor
[✓] Flutter (Channel dev, 1.27.0-8.0.pre, on Microsoft Windows [Version 10.0.19042.804], locale zh-CN)
• Flutter version 1.27.0-8.0.pre at D:\FlutterStudy\flutter
• Framework revision b7d4806243 (10 days ago), 2021-02-19 09:22:45 -0800
• Engine revision 6993cb229b
• Dart version 2.13.0 (build 2.13.0-30.0.dev)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
• Android SDK at C:\Users\tilongzs\AppData\Local\Android\sdk
• Platform android-30, build-tools 30.0.3
• Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
• All Android licenses accepted.
[✗] Chrome - develop for the web (Cannot find Chrome executable at .\Google\Chrome\Application\chrome.exe)
! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.
[✓] Visual Studio - develop for Windows (Visual Studio Professional 2019 16.8.6)
• Visual Studio at C:\Program Files\VS2019
• Visual Studio Professional 2019 version 16.8.31019.35
• Windows 10 SDK version 10.0.18362.0
[✓] Android Studio (version 4.1.0)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
[✓] Connected device (2 available)
• Windows (desktop) • windows • windows-x64 • Microsoft Windows [Version 10.0.19042.804]
• Edge (web) • edge • web-javascript • Microsoft Edge 88.0.705.81
! Doctor found issues in 1 category.
[✓] Flutter (Channel dev, 1.27.0-8.0.pre, on Microsoft Windows [Version 10.0.19042.804], locale zh-CN)
• Flutter version 1.27.0-8.0.pre at D:\FlutterStudy\flutter
• Framework revision b7d4806243 (10 days ago), 2021-02-19 09:22:45 -0800
• Engine revision 6993cb229b
• Dart version 2.13.0 (build 2.13.0-30.0.dev)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
• Android SDK at C:\Users\tilongzs\AppData\Local\Android\sdk
• Platform android-30, build-tools 30.0.3
• Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
• All Android licenses accepted.
[✗] Chrome - develop for the web (Cannot find Chrome executable at .\Google\Chrome\Application\chrome.exe)
! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.
[✓] Visual Studio - develop for Windows (Visual Studio Professional 2019 16.8.6)
• Visual Studio at C:\Program Files\VS2019
• Visual Studio Professional 2019 version 16.8.31019.35
• Windows 10 SDK version 10.0.18362.0
[✓] Android Studio (version 4.1.0)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
[✓] Connected device (2 available)
• Windows (desktop) • windows • windows-x64 • Microsoft Windows [Version 10.0.19042.804]
• Edge (web) • edge • web-javascript • Microsoft Edge 88.0.705.81
! Doctor found issues in 1 category.