|
|
|
@ -2,6 +2,7 @@ import 'package:flutter/widgets.dart' show BuildContext; |
|
|
|
|
import 'package:meta/meta.dart' show immutable; |
|
|
|
|
|
|
|
|
|
import 'image.dart'; |
|
|
|
|
import 'video.dart'; |
|
|
|
|
|
|
|
|
|
enum CameraAction { |
|
|
|
|
video, |
|
|
|
@ -22,7 +23,10 @@ class QuillToolbarCameraConfigurations { |
|
|
|
|
this.onRequestCameraActionCallback, |
|
|
|
|
OnImageInsertCallback? onImageInsertCallback, |
|
|
|
|
this.onImageInsertedCallback, |
|
|
|
|
}) : _onImageInsertCallback = onImageInsertCallback; |
|
|
|
|
this.onVideoInsertedCallback, |
|
|
|
|
OnVideoInsertCallback? onVideoInsertCallback, |
|
|
|
|
}) : _onImageInsertCallback = onImageInsertCallback, |
|
|
|
|
_onVideoInsertCallback = onVideoInsertCallback; |
|
|
|
|
|
|
|
|
|
final OnRequestCameraActionCallback? onRequestCameraActionCallback; |
|
|
|
|
|
|
|
|
@ -33,4 +37,12 @@ class QuillToolbarCameraConfigurations { |
|
|
|
|
OnImageInsertCallback get onImageInsertCallback { |
|
|
|
|
return _onImageInsertCallback ?? defaultOnImageInsertCallback(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
final OnVideoInsertedCallback? onVideoInsertedCallback; |
|
|
|
|
|
|
|
|
|
final OnVideoInsertCallback? _onVideoInsertCallback; |
|
|
|
|
|
|
|
|
|
OnVideoInsertCallback get onVideoInsertCallback { |
|
|
|
|
return _onVideoInsertCallback ?? defaultOnVideoInsertCallback(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|