shekohex / flutterust

Flutter + Rust = :heart:
Apache License 2.0
699 stars 56 forks source link

method 'RaisedButton' isn't defined for the class '_MyHomePageState' #45

Closed davehorner closed 1 year ago

davehorner commented 1 year ago

I was able to get all of cargo make to work on windows. I had to add the --no-sound-null-safety as another issue suggested.

Any ideas why I find this RaisedButton isn't defined?

`c:\working\flutter\flutterust>flutter run --no-sound-null-safety Using hardware rendering with device sdk gphone64 x86 64. If you notice graphics artifacts, consider enabling software rendering with "--enable-software-rendering". Launching lib\main.dart on sdk gphone64 x86 64 in debug mode... lib/main.dart:56:13: Error: The method 'RaisedButton' isn't defined for the class '_MyHomePageState'.

FAILURE: Build failed with an exception.

BUILD FAILED in 15s Running Gradle task 'assembleDebug'... 16.1s Exception: Gradle task assembleDebug failed with exit code 1`

davehorner commented 1 year ago

RaisedButton has been deprecated in favor of ElevatedButton. color named parameter is no longer valid, I just commented out the color line.