-
-
Notifications
You must be signed in to change notification settings - Fork 33
Closed
Description
I am new to flutter.
I want to make a screen recorder app .
I used this plugin and your example code but I have 3 errors.
D:\screenrecorder>flutter run
Launching lib\main.dart on SM M307F in debug mode...
lib/main.dart:22:19: Error: The parameter 'key' can't have a value of 'null' because of its type 'Key', but the implicit default value is
'null'.
- 'Key' is from 'package:flutter/src/foundation/key.dart' ('/C:/flutter/packages/flutter/lib/src/foundation/key.dart').
Try adding either an explicit non-'null' default value or the 'required' modifier.
MyHomePage({Key key, this.title}) : super(key: key);
^^^
lib/main.dart:22:29: Error: The parameter 'title' can't have a value of 'null' because of its type 'String', but the implicit default value
is 'null'.
Try adding either an explicit non-'null' default value or the 'required' modifier.
MyHomePage({Key key, this.title}) : super(key: key);
^^^^^
lib/main.dart:83:45: Error: The argument type 'List<int>?' can't be assigned to the parameter type 'Uint8List'.
- 'List' is from 'dart:core'.
- 'Uint8List' is from 'dart:typed_data'.
content: Image.memory(gif),
^
FAILURE: Build failed with an exception.
* Where:
Script 'C:\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1035
* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command 'C:\flutter\bin\flutter.bat'' finished with non-zero exit value 1
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to
get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 1m 17s
Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 81.3s
Exception: Gradle task assembleDebug failed with exit code 1
Error at this two lines
- https://github.com/ueman/screenrecorder/blob/main/example/lib/main.dart#L22
- https://github.com/ueman/screenrecorder/blob/main/example/lib/main.dart#L83
How can I solve this ?
Metadata
Metadata
Assignees
Labels
No labels