google / flutter-desktop-embedding

Experimental plugins for Flutter for Desktop
Apache License 2.0
7.1k stars 607 forks source link

Avoid warnin: this old-style function definition is not preceded by a prototype when building window_size plugin on macOS #855

Closed rwbr closed 3 years ago

rwbr commented 3 years ago

When building the window_size plugin for macOS, the compiler creates the following warning:

.../plugins/window_size/macos/Classes/FLEWindowSizePlugin.m:39:22: warning: this old-style function definition is not preceded by a prototype [-Wstrict-prototypes]
CGFloat GetMaxScreenY() {                                               
                     ^                                                  
1 warning generated.

My environment:

❯ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.2.0, on macOS 11.3.1 20E241 darwin-x64, locale de-DE)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS
[✓] Chrome - develop for the web
[✓] Android Studio (version 3.6)
[✓] VS Code (version 1.56.2)
[✓] Connected device (2 available)

Xcode is version 12.5 (12E262)