esysberlin / esys-flutter-share Goto Github PK
View Code? Open in Web Editor NEWA Flutter plugin for sharing files & text with other applications.
License: Apache License 2.0
A Flutter plugin for sharing files & text with other applications.
License: Apache License 2.0
esys_flutter_share plugin is giving below error when I use it with any 'Permission' plugin. Please assist
dependencies in pubspec.yaml
cupertino_icons: ^0.1.2
dynamic_theme: ^1.0.1
sqflite: ^1.1.1
path_provider: ^0.5.0+1
simple_permissions: ^0.1.9
esys_flutter_share: ^1.0.1
intl: ^0.15.8
flutter_html: ^0.9.6
FAILURE: Build failed with an exception.
com.android.builder.dexing.DexArchiveMergerException: Error while merging dex archives: D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\2.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\3.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\4.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\5.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\6.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\7.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\8.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\9.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\10.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\11.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\12.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\13.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\14.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\15.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\16.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\17.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\18.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\19.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\20.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\21.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\22.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\23.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\24.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\25.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\26.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\27.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\28.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\29.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\30.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\31.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\32.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\33.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\34.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\35.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\36.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\37.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\38.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\39.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\40.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\41.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\42.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\43.jar, D:\Flutter\Practice\mytestnote\build\app\intermediates\transforms\dexBuilder\debug\44.jar
Learn how to resolve the issue at https://developer.android.com/studio/build/dependencies#duplicate_classes.
Program type already present: android.support.v4.media.MediaBrowserCompat$CallbackHandler
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 17s
Gradle task assembleDebug failed with exit code 1
Exited (sigterm)
Migrate the plugin to AndroidX.
Describe the bug
When I try the “save file” option on the iOS sharing intent. I can share to anything else (twitter, iMessage, dropbox, etc), and it works as expected, but if I choose “Save file”, it crashes my flutter app, even with the try/catch.
To Reproduce
Future<Uint8List> getCurrentImage() async {
RenderRepaintBoundary rpb =
boardGlobalKey.currentContext.findRenderObject();
ui.Image img = await rpb.toImage();
ByteData byteData = await img.toByteData(format: ui.ImageByteFormat.png);
return byteData.buffer.asUint8List();
}
Future<void> shareImage() async {
try {
await Share.file(
'Pedalboard Image',
'pedalboard.png',
await getCurrentImage(),
'image/png',
);
} catch (e) {
debugPrint(e.toString());
}
}
on iOS, then choose "Save File"
Expected behavior
file is saved to device
Smartphone (please complete the following information):
Describe the bug
In the latest version of instagram (133.0.0.32.120 ) it only creates problems when feeding pictures
Instagram story and video feature works well but just sharing image to instagram feed doesn't work.
However every feature works well in the previous version of Instagram (132.0.0.26.134 )
Expected behavior
Image file is expected to shared to feed via instagram latest version
Smartphone (please complete the following information):
Additional context
Please help how to solve instagram to feed image in the instagram latest version(133.0.0.32.120).
Error while run project after installing package with 0.0.7
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:processDebugResources'.
> Android resource linking failed
Output: E:\git\flutter_app_list\valentine_msg\build\app\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:189: error: resource android:attr/fontVariationSettings not found.
E:\git\flutter_app_list\valentine_msg\build\app\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:190: error: resource android:attr/ttcIndex not found.
error: failed linking references.
Command: C:\Users\Nirav\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.1-4818971-windows.jar\83687d66e89ec7b8cc2f4a4ae88da52a\aapt2-3.2.1-4818971-windows\aapt2.exe link -I\
E:\Android\sdk\platforms\android-27\android.jar\
--manifest\
E:\git\flutter_app_list\valentine_msg\build\app\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
-o\
E:\git\flutter_app_list\valentine_msg\build\app\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
-R\
@E:\git\flutter_app_list\valentine_msg\build\app\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
E:\git\flutter_app_list\valentine_msg\build\app\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
--custom-package\
com.nikks.valentine.valentinemsg\
-0\
apk\
--output-text-symbols\
E:\git\flutter_app_list\valentine_msg\build\app\intermediates\symbols\debug\R.txt\
--no-version-vectors
Daemon: AAPT2 aapt2-3.2.1-4818971-windows Daemon #0
Output: C:\Users\Nirav\.gradle\caches\transforms-1\files-1.1\support-compat-28.0.0.aar\7a8b1538ce3b022346e00d07f155af4a\res\values\values.xml:89:5-125:25: AAPT: error: resource android:attr/fontVariationSettings not found.
C:\Users\Nirav\.gradle\caches\transforms-1\files-1.1\support-compat-28.0.0.aar\7a8b1538ce3b022346e00d07f155af4a\res\values\values.xml:89:5-125:25: AAPT: error: resource android:attr/ttcIndex not found.
error: failed linking references.
Command: C:\Users\Nirav\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.1-4818971-windows.jar\83687d66e89ec7b8cc2f4a4ae88da52a\aapt2-3.2.1-4818971-windows\aapt2.exe link -I\
E:\Android\sdk\platforms\android-27\android.jar\
--manifest\
E:\git\flutter_app_list\valentine_msg\build\app\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
-o\
E:\git\flutter_app_list\valentine_msg\build\app\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
-R\
@E:\git\flutter_app_list\valentine_msg\build\app\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
E:\git\flutter_app_list\valentine_msg\build\app\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
--custom-package\
com.nikks.valentine.valentinemsg\
-0\
apk\
--output-text-symbols\
E:\git\flutter_app_list\valentine_msg\build\app\intermediates\symbols\debug\R.txt\
--no-version-vectors
Daemon: AAPT2 aapt2-3.2.1-4818971-windows Daemon #0
* 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 35s
Finished with error: Gradle task assembleDebug failed with exit code 1
E:\Android\sdk\flutter\bin\flutter.bat doctor --verbose
[√] Flutter (Channel beta, v1.0.0, on Microsoft Windows [Version 10.0.16299.847], locale en-IN)
• Flutter version 1.0.0 at E:\Android\sdk\flutter
• Framework revision 5391447fae (5 weeks ago), 2018-11-29 19:41:26 -0800
• Engine revision 7375a0f414
• Dart version 2.1.0 (build 2.1.0-dev.9.4 f9ebf21297)
Describe the bug
When I click on the button that triggers share action, on iPad OS (and, perhaps, on Android tablets?) the Share modal window appears, but it's located far from the actual button, and there is no way to specify position.
To Reproduce
Create Scaffold with action button that triggers Share action with this plugin. Run on iPad. Click on the button (which is on the top right side), and observe Share modal window appear in the top left corner.
Expected behavior
Share modal window appears close to the button that triggered the action.
Additional context
In the official Share plugin they have parameter for specifying the origin. It worked fine for me, when I was using that plugin: https://github.com/flutter/plugins/blob/master/packages/share/example/lib/main.dart#L69
Builder(
builder: (BuildContext context) {
return RaisedButton(
child: const Text('Share'),
onPressed: text.isEmpty
? null
: () {
// A builder is used to retrieve the context immediately
// surrounding the RaisedButton.
//
// The context's `findRenderObject` returns the first
// RenderObject in its descendent tree when it's not
// a RenderObjectWidget. The RaisedButton's RenderObject
// has its position and size after it's built.
final RenderBox box = context.findRenderObject();
Share.share(text,
subject: subject,
sharePositionOrigin:
box.localToGlobal(Offset.zero) &
box.size);
},
);
},
I have a Container holding my images.
Container( child: Stack( children: <Widget>[ Align( alignment: Alignment.center, child: Hero( tag: widget.imageList, child: Img( ayo: widget.imageList, ), ),
How can be able to share the particluar image the container is holding at the moment. Because there are various images in my image folder.
Thank you for creating very useful plugin.
Android build works without problem.
But I had got the error below in iOS build.
Is there anyone who has any idea to solve this?
Launching lib/main.dart on iPhone XR in debug mode...
Running pod install...
Starting Xcode build...
Xcode build done. 13.6s
Failed to build iOS app
Error output from Xcode build:
↳
** BUILD FAILED **
Xcode's output:
↳
=== BUILD TARGET url_launcher OF PROJECT Pods WITH CONFIGURATION Debug ===
/Users/devneko/opt/flutter/.pub-cache/hosted/pub.dartlang.org/app_review-0.0.9/ios/Classes/AppReviewPlugin.m:2:9: fatal error: 'app_review/app_review-Swift.h' file not found
#import <app_review/app_review-Swift.h>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
/Users/devneko/opt/flutter/.pub-cache/hosted/pub.dartlang.org/esys_flutter_share-0.0.5/ios/Classes/EsysFlutterSharePlugin.m:2:9: fatal error: 'esys_flutter_share/esys_flutter_share-Swift.h' file not found
#import <esys_flutter_share/esys_flutter_share-Swift.h>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
Could not build the application for the simulator.
Error launching application on iPhone XR.
How to share images from urls?
E/flutter (28780): [ERROR:flutter/shell/common/shell.cc(184)] Dart Error: Unhandled exception: E/flutter (28780): MissingPluginException(No implementation found for method shareImage on channel channel:github.com/orgs/esysberlin/esys-flutter-share) E/flutter (28780): #0 MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:291:7) E/flutter (28780): <asynchronous suspension> E/flutter (28780): #1 EsysFlutterShare.shareImage (package:esys_flutter_share/esys_flutter_share.dart:34:14) E/flutter (28780): <asynchronous suspension> E/flutter (28780): #2 RoutineDetailPageState._shareImage (package:WorkoutPlanner/routineDetailPage.dart:199:30) E/flutter (28780): <asynchronous suspension> E/flutter (28780): #3 RoutineDetailPageState.build.<anonymous closure>.<anonymous closure>.<anonymous closure> (package:WorkoutPlanner/routineDetailPage.dart:95:60) E/flutter (28780): #4 _InkResponseState._handleTap (package:flutter/src/material/ink_well.dart:507:14) E/flutter (28780): #5 _InkResponseState.build.<anonymous closure> (package:flutter/src/material/ink_well.dart:562:30) E/flutter (28780): #6 GestureRecognizer.invokeCallback (package:flutter/src/gestures/recognizer.dart:102:24) E/flutter (28780): #7 TapGestureRecognizer._checkUp (package:flutter/src/gestures/tap.dart:242:9) E/flutter (28780): #8 TapGestureRecognizer.handlePrimaryPointer (package:flutter/src/gestures/tap.dart:175:7) E/flutter (28780): #9 PrimaryPointerGestureRecognizer.handleEvent (package:flutter/src/gestures/recognizer.dart:315:9) E/flutter (28780): #10 PointerRouter._dispatch (package:flutter/src/gestures/pointer_router.dart:73:12) E/flutter (28780): #11 PointerRouter.route (package:flutter/src/gestures/pointer_router.dart:101:11) E/flutter (28780): #12 _WidgetsFlutterBinding&BindingBase&GestureBinding.handleEvent (package:flutter/src/gestures/binding.dart:180:19) E/flutter (28780): #13 _WidgetsFlutterBinding&BindingBase&GestureBinding.dispatchEvent (package:flutter/src/gestures/binding.dart:158:22) E/flutter (28780): #14 _WidgetsFlutterBinding&BindingBase&GestureBinding._handlePointerEvent (package:flutter/src/gestures/binding.dart:138:7) E/flutter (28780): #15 _WidgetsFlutterBinding&BindingBase&GestureBinding._flushPointerEventQueue (package:flutter/src/gestures/binding.dart:101:7) E/flutter (28780): #16 _WidgetsFlutterBinding&BindingBase&GestureBinding._handlePointerDataPacket (package:flutter/src/gestures/binding.dart:85:7) E/flutter (28780): #17 _invoke1 (dart:ui/hooks.dart:168:13) E/flutter (28780): #18 _dispatchPointerDataPacket (dart:ui/hooks.dart:122:5)
I get this when I try to share an image
E/DatabaseUtils( 9486): java.lang.SecurityException: Permission Denial: reading de.esys.esysfluttershare.EsysFlutterShareFileProvider uri content://com.gorjan.airquality.fileprovider.github.com%2Forgs%2Fesysberlin%2Fesys-flutter-share/files/aircare.png from pid=8132, uid=1000 requires the provider be exported, or grantUriPermission()
E/DatabaseUtils( 9486): at android.content.ContentProvider.enforceReadPermissionInner(ContentProvider.java:729)
E/DatabaseUtils( 9486): at android.content.ContentProvider$Transport.enforceReadPermission(ContentProvider.java:602)
E/DatabaseUtils( 9486): at android.content.ContentProvider$Transport.enforceFilePermission(ContentProvider.java:593)
E/DatabaseUtils( 9486): at android.content.ContentProvider$Transport.openTypedAssetFile(ContentProvider.java:507)
E/DatabaseUtils( 9486): at android.content.ContentProviderNative.onTransact(ContentProviderNative.java:307)
E/DatabaseUtils( 9486): at android.os.Binder.execTransactInternal(Binder.java:1021)
E/DatabaseUtils( 9486): at android.os.Binder.execTransact(Binder.java:994)
The sharing somehow succeeds still, but this expectation is printed in the console.
Please consider this as a request to add the feature of sharing text or image or both to a particular application.... like whatsapp.
LJM:flu_app_fe vinbeeluo$ flutter build apk
Initializing gradle... 4.6s
Resolving dependencies... 10.6s
注: /Library/flutter/.pub-cache/hosted/pub.flutter-io.cn/esys_flutter_share-1.0.1/android/src/main/java/de/esys/esysfluttershare/EsysFlutterSharePlugin.ava使用了未经检查或不安全的操作。
注: 有关详细信息, 请使用 -Xlint:unchecked 重新编译。
Calling mockable JAR artifact transform to create file: /Users/vinbeeluo/.gradle/caches/transforms-1/files-1.1/android.jar/e2dc5fd512a35e23c34d1e209fd43d11/android.jar with input /Users/vinbeeluo/Library/Android/sdk/platforms/android-28/android.jar
Calling mockable JAR artifact transform to create file: /Users/vinbeeluo/.gradle/caches/transforms-1/files-1.1/android.jar/90bc6d07db5b53f4236cf7be92d2f0d0/android.jar with input /Users/vinbeeluo/Library/Android/sdk/platforms/android-27/android.jar
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':fluttertoast:verifyReleaseResources'.
> java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
/Users/vinbeeluo/Desktop/Git/flu_app_fe/build/fluttertoast/intermediates/res/merged/release/values-v28/values-v28.xml:7: error: resource android:attr/dialogCornerRadius not found.
/Users/vinbeeluo/Desktop/Git/flu_app_fe/build/fluttertoast/intermediates/res/merged/release/values-v28/values-v28.xml:11: error: resource android:attr/dialogCornerRadius not found.
/Users/vinbeeluo/Desktop/Git/flu_app_fe/build/fluttertoast/intermediates/res/merged/release/values/values.xml:2601: error: resource android:attr/fontVariationSettings not found.
/Users/vinbeeluo/Desktop/Git/flu_app_fe/build/fluttertoast/intermediates/res/merged/release/values/values.xml:2602: error: resource android:attr/ttcIndex not found.
error: failed linking references.
* 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 18s
Running Gradle task 'assembleRelease'...
Running Gradle task 'assembleRelease'... Done 79.3s
Gradle task assembleRelease failed with exit code 1
LJM:flu_app_fe vinbeeluo$
Currently, i want to share my image with other apps using esys_flutter_share and wc_flutter_share Plugin using following code.
import 'package:esys_flutter_share/esys_flutter_share.dart' as esysShare;
import 'package:wc_flutter_share/wc_flutter_share.dart';
import 'package:flutter/material.dart';
import 'package:extended_image/extended_image.dart';
@override
Widget build(BuildContext context) {
return Scaffold(
body: Center(
child: ExtendedImage.network(
"https://picsum.photos/250?image=9",
fit: BoxFit.cover,
width: 250,
height: 250,
//enableLoadState: false,
mode: ExtendedImageMode.gesture,
loadStateChanged: (ExtendedImageState state) {
switch (state.extendedImageLoadState) {
case LoadState.completed:
return GestureDetector(
onTap: () async {
ByteData data=await state.extendedImageInfo.image.toByteData();
print("data : ${data}");
Uint8List list=data.buffer.asUint8List();
print("list : ${list}");
// EasyFlutterShare plugin not working. It is also giving me a blackend screen as attached image
esysShare.Share.file("Share Image", "Test.png", list, "image/png");
// Even WcFlutterShare plugin not working. It is also giving me a blackend screen as attached image
WcFlutterShare.share(sharePopupTitle: "Share Image 2", mimeType: "image/*",bytesOfFile: list,fileName: "Test.png");
},
child: ExtendedRawImage(
image: state.extendedImageInfo?.image,
width: 250,
height: 250,
),
);
break;
case LoadState.loading:
return Center(
child: CircularProgressIndicator(
valueColor: AlwaysStoppedAnimation<Color>(Colors.blueAccent),
),
);
break;
case LoadState.failed:
return Center(
child: CircularProgressIndicator(
valueColor:
AlwaysStoppedAnimation<Color>(Colors.deepOrangeAccent),
),
);
break;
}
},
initGestureConfigHandler: (state) {
return GestureConfig(
minScale: 0.9,
animationMinScale: 0.7,
maxScale: 3.0,
animationMaxScale: 3.5,
speed: 1.0,
inertialSpeed: 100.0,
initialScale: 1.0,
inPageView: false);
},
),
),
);
}
I didn't get any errors. But, my screen gets blackened while share the image.
Both plugins are giving me a black screen as attached image in my case.
Suggest a work-around solution.
Hi,
When user selects Gmail app in Share options, how i can pass predefined email addresses to mail composer as To/CC/BCC, and also Subject.
If there is anyway to achieve it.
Please let me know
Thank you.
A clear and concise description of what the bug is.
FAILURE: Build failed with an exception.
* Where:
Script '/Users/builder/programs/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 221
* What went wrong:
A problem occurred configuring project ':esys_flutter_share'.
> Failed to notify project evaluation listener.
> Could not get unknown property 'android' for project ':esys_flutter_share' of type org.gradle.api.Project.
> Could not find method debugProvided() for arguments [file collection] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.
* 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 20s
Build failed :|
Unable to initialize project data from Gradle build file:
A problem occurred configuring project ':esys_flutter_share'.
I am trying to share the image which is in Uint8List format.
The image is basically a white container with a black text in it.
But when the Image is shared, the background somehow becomes black and the image is not visible as the text is already black.
I have a scaffol and some fields and a logo wrapped in a Screenshot widget. When i generate the file with screenshot and share it on whatsapp the image is black.
The code is above
return Scaffold(
backgroundColor: Colors.white,
floatingActionButton: FloatingActionButton(onPressed: () async {
await takeScreenShot();
}, child: Icon(Icons.share),),
body: Screenshot(
controller: screenshotController,
child: Padding(
padding: const EdgeInsets.all(20.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Text(
'Rodrigo Bastos Vasconcelos'.toUpperCase(),
style: TextStyle(fontSize: 24.0),
),
Text(
'Cientista da Computação',
style: TextStyle(fontSize: 18.0),
),
Divider(
thickness: 2.0,
),
Row(
children: <Widget>[
Expanded(
child: Column(
children: <Widget>[
Padding(
padding: const EdgeInsets.symmetric(vertical: 12.0),
child: Row(
children: <Widget>[
CircleAvatar(child: Icon(Icons.phone_android)),
SizedBox(width: 12.0,),
Text('(85) 996762196')
],
),
),
Padding(
padding: const EdgeInsets.symmetric(vertical: 12.0),
child: Row(
children: <Widget>[
CircleAvatar(child: Icon(Icons.whatshot)),
SizedBox(width: 12.0,),
Text('(85) 996762196')
],
),
),
Padding(
padding: const EdgeInsets.symmetric(vertical: 12.0),
child: Row(
children: <Widget>[
CircleAvatar(child: Icon(Icons.email)),
SizedBox(width: 12.0,),
Text('[email protected]')
],
),
),
],
),
),
Expanded(
child: Image.asset('logo.png', width: 100.0, height: 100.0, fit: BoxFit.contain,),
)
],
)
],
),
),
),
);
}
takeScreenShot() async {
File imageFile = await screenshotController.capture();
Uint8List bytes = await imageFile.readAsBytes();
await Share.file('esys image', 'esys.png', bytes.buffer.asUint8List(), 'image/png', text: 'My optional text.');
}```
I see that android can share to instagram story but iOS cant. Are there any plans to enhance this?
Describe the bug
I tried with an emulator and I found no issues. However, when I try on my device (Xiaomi Note 8T with Android 9) I get this error:
Unable to load asset: /storage/emulated/0/Android/data/drodriguez.apps.Words/files/Pictures/scaled_5131ca60-c7c6-4988-95fc-65da2a67724c3738022373876670064.jpg
This is a picture I have taken on my app.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
I should be able to share the picture taken
Smartphone (please complete the following information):
A call of Share.file(...)
produces an error on iPad-s (both simulator and device). On iPhones works as expected.
The error is:
Probably at least one of the constraints in the following list is one you don't want.
Try this:
(1) look at each constraint and try to figure out which you don't expect;
(2) find the code that added the unwanted constraint or constraints and fix it.
(
"<NSLayoutConstraint:0x600001ef3110 LPLinkView:0x7fa1d6f87110.leading == UILayoutGuide:0x600000442ca0'UIViewLayoutMarginsGuide'.leading (active)>",
"<NSLayoutConstraint:0x600001ef2f80 H:[LPLinkView:0x7fa1d6f87110]-(59)-| (active, names: '|':_UIActivityContentTitleView:0x7fa1d6f86bf0 )>",
"<NSLayoutConstraint:0x600001ee8780 H:|-(0)-[_UIActivityContentTitleView:0x7fa1d6f86bf0] (active, names: '|':_UINavigationBarContentView:0x7fa1d6f8dad0 )>",
"<NSLayoutConstraint:0x600001eeaad0 _UIActivityContentTitleView:0x7fa1d6f86bf0.trailing == _UINavigationBarContentView:0x7fa1d6f8dad0.trailing (active)>",
"<NSLayoutConstraint:0x600001ec4640 'UIView-Encapsulated-Layout-Width' _UINavigationBarContentView:0x7fa1d6f8dad0.width == 0 (active)>",
"<NSLayoutConstraint:0x600001ef3020 'UIView-leftMargin-guide-constraint' H:|-(16)-[UILayoutGuide:0x600000442ca0'UIViewLayoutMarginsGuide'](LTR) (active, names: '|':_UIActivityContentTitleView:0x7fa1d6f86bf0 )>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x600001ef3110 LPLinkView:0x7fa1d6f87110.leading == UILayoutGuide:0x600000442ca0'UIViewLayoutMarginsGuide'.leading (active)>
Found similar issue with flutter share plugin flutter/flutter#44962 in case this might help.
bash$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.9.1+hotfix.6, on Mac OS X 10.15.1 19B88, locale en-RU)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 11.2.1)
[✓] Android Studio (version 3.5)
[✓] IntelliJ IDEA Ultimate Edition (version 2019.1.4)
[✓] Connected device (1 available)
esys_flutter_share version 1.0.2
does not specify a Swift version and none of the targets (
Runner) integrating it have the
SWIFT_VERSIONattribute set. Please contact the author or set the
SWIFT_VERSIONattribute in at least one of the targets that integrate this pod. -
wc_flutter_share does not specify a Swift version and none of the targets (
Runner) integrating it have the
SWIFT_VERSIONattribute set. Please contact the author or set the
SWIFT_VERSION` attribute in at least one of the targets that integrate this pod.
We get this warning when we run the app:
EsysFlutterSharePlugin.java uses unchecked or unsafe operations.
I think this comes up in Java 5 and later if you're using collections without type specifiers (e.g., Arraylist() instead of ArrayList()). It means that the compiler can't check that you're using the collection in a type-safe way, using generics.
To get rid of the warning, just be specific about what type of objects you're storing in the collection. So, instead of
List myList = new ArrayList();
use
List myList = new ArrayList();
or in java7: List myList = new ArrayList<>();
(remark : you still need angle brackets)
Is your feature request related to a problem? Please describe.
Using this to share multiple images which are selected similar to google photos. The outcome of the share is unknown and I would like to know if the photos were shared or if the action was canceled or failed so I can appropriately deselect the photos if they were in fact shared and keep them selected if they were not.
Describe the solution you'd like
On bearer dismissal of the share dialog or errors during sharing return false. Otherwise, if the share is believed to be successful return true.
Describe alternatives you've considered
Not sure of other alternatives but would be open to suggestions
Additional context
Making share work similar to google photos and iOS photos apps
Hello everyone, I'm trying to share images in my app, but with the esys-flutter-share version 1.0.1 I cannot share images from some particular folders such as from Whatsapp folder, previously with version 0.0.7 I was able to share all the photos but now with this latest version I cannot share all the photos. As with photos from whatsapp my code doesn't go to the 2nd line of this code, it just exits from the 1st line
final ByteData bytes = await rootBundle.load(widget.image.path);
await Share.file('Sharing the best Captions & Hashtags directly from the App!', 'esys.png', bytes.buffer.asUint8List(), 'image/png');
I'm able to get the path in both cases but in the 2nd case, it doesn't go to the second line.
Please help me solve this problem as the app is live and needed to update the app asap. TIA
It returns error:
<asynchronous suspension>
#1 Share.text (package:esys_flutter_share/esys_flutter_share.dart:18:14)
#2 _ReportScreenState.build.<anonymous closure> (package:news_wire/screens/report.dart:76:21)
#3 _InkResponseState._handleTap (package:flutter/src/material/ink_well.dart:635:14)
#4 _InkResponseState.build.<anonymous closure> (package:flutter/src/material/ink_well.dart:711:32)
#5 GestureRecognizer.invokeCallback (package:flutter/src/gestures/recognizer.dart:182:24)
#6 TapGestureRecognizer._checkUp (package:flutter/src/gestures/tap.dart:365:11)
#7 TapGestureRecognizer.handlePrimaryPointer (package:flutter/src/gestures/tap.dart:275:7)
#8 PrimaryPointerGestureRecognizer.handleEvent (package:flut<…>
I am getting the following error
problem occurred configuring root project 'esys_flutter_share'.
SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable.
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 12s
The plugin esys_flutter_share could not be built due to the issue above.
Exited (sigterm)
my local.properties in my android directory
sdk.dir=C:\Users\me\AppData\Local\Android\sdk
flutter.sdk=C:\flutter
flutter.buildMode=debug
flutter.versionName=1.0.0
flutter.versionCode=1
here is my flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel beta, v1.14.6, on Microsoft Windows [Version 10.0.17763.973], locale en-US)
[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
[√] Android Studio (version 3.4)
[√] IntelliJ IDEA Ultimate Edition (version 2018.3)
[√] VS Code, 64-bit edition
[√] Connected device (1 available)
fatal error: 'esys_flutter_share/esys_flutter_share-Swift.h' file not found
#import <esys_flutter_share/esys_flutter_share-Swift.h>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Hi!
I've a list of refs of images stored in Firestore. According your READ of plugin I can share single
image but I need more - ho to share all images from a list? Thanks!
Thank you for your time!
Hi, thanks for the wonderful plugin i am using the cache manager and rather than download the image i am trying to share an image from cache manager like so
try {
final ByteData bytes = await rootBundle.load(path);
await Share.file(
fileName, fileName, bytes.buffer.asUint8List(), 'image/png',
text: 'Shared from myApp');
} catch (e) {
print('error: $e');
}
i am getting the path from cache manager like
Future<String> findCachedImagePath(String imageUrl) async {
var file = await DefaultCacheManager().getSingleFile(imageUrl);
return file.path;
}
and it returns to me this string
/data/user/0/com.example.myApp/cache/libCachedImageData/e6cb8eb0-c1a7-11e9-8d36-096d03933f81.jpeg
however on trying to share i get this error
error: FileSystemException: Cannot create file, path = '/data/user/0/com.example.myApp/cache/' (OS Error: Is a directory, errno = 21)
help would be appriciated, thanks
If I share an mp3 file along with text and title using Share.file function, only audio is being shared but not the title and optional text.
Platform tested : Android.
I am using
await Share.file('esys image', 'esys.png', bytes.buffer.asUint8List(), 'image/png', text: 'My optional text.');
like in your example.
On Android, the TITLE from the method does not appear as the Subject in GMAIL or YAHOO app.
I wish that the title of the method would be shared as TITLE on the email apps, both on Android and on iOS.
I know it's possible on Android using java native, not sure about iOS.
unfortunately we cannot use the title property if we share a picture, as we can do when sharing a text, it's really annoying..
Is it possible to share multiple images and videos simultaneously ?
A requested feature is to share images and text simultaneously like proposed in this commit.
I am building app with Codemagic and android builds fine but iOS build fails and it says:
- Running pre install hooks
[!] Unable to determine Swift version for the following pods:
- `esys_flutter_share` does not specify a Swift version and none of the targets (`Runner`) integrating it have the `SWIFT_VERSION` attribute set. Please contact the author or set the `SWIFT_VERSION` attribute in at least one of the targets that integrate this pod.
and i have added config.build_settings['SWIFT_VERSION'] = '4.0'
to Podfile... But the same error appears.
Describe the bug
When trying to share to WhatsApp on iOS, the image is not being shared. But image is being is share to Gmail or any other app.
To Reproduce
Share file to WhatsApp on iOS via OS share menu. And also trying sharing a file to Gmail App via the same OS share menu. Only WhatsApp share is not bearing the image. However, the same is working on Android
Expected behaviour
Image file is expected to get shared via WhatsApp
Screen Record
https://youtu.be/JOzddotsIeY
Smartphone
Additional Context
Generating the screenshot image using screenshot pub (v0.1.1)
I'm using shareImage method to share a pdf and it's working smoothly on android. but this is the error i get when i try it on ios warning: could not execute support code to read Objective-C class data in the process. This may reduce the quality of type information available.
and it makes my app crash
Hi
This beautiful plugin opens all the system app including whatsapp.
Can i just specifically choose whatsapp, facebook messanger or snapchat?
I would like to have "share on whatsapp" in my app.
I'd like to share multiples images, but currently each image is shared with a text.
The text is a little big, so sharing the same picture with the same text could annoying for the user
Hello, I am testing my fluttter application with my android 10 device. I try to share an image from network image. But in android 10 devices can not share image into instagram feed. But i can share into instagram story.. whats the difference ?
If anyone test this case in Android 10..
I am using below code
void onShareImage(String url) async { var request = await HttpClient().getUrl(Uri.parse(url)); var response = await request.close(); Uint8List bytes = await consolidateHttpClientResponseBytes(response); await Share.file('myImage', 'myImage.jpg', bytes, 'image/jpg'); }
This share method works with well at all social networks. But instagram feed and messenger story can not share image..
So I have Integrated esys_flutter_share 1.0.2 and it was working fine on my moto g4 mobile, but after testing on Samsung s10, s10+, note10 and s9+ when I click on the share button the share popup menu never comes out. But it is working on moto g4, g5, one plus 7. The code I used for sharing is as-
final ByteData bytes = await rootBundle.load(image.path);
await Share.file(' ', 'esys.png', bytes.buffer.asUint8List(), 'image/png', text: widget.link ?? "mydeeplink");
I don't have console logs as I was testing on browser stack and could not find any.
When trying to use the share button on an iPad I get the following output and cannot share my image:
`2020-04-15 11:06:04.410131-0500 Vitrix Health[16637:5319295] [ShareSheet] connection invalidated
2020-04-15 11:06:06.985271-0500 Vitrix Health[16637:5310642] flutter: Sharing image
2020-04-15 11:06:06.985390-0500 Vitrix Health[16637:5310642] flutter: /private/var/mobile/Containers/Data/Application/DCD63FC0-340C-4B0F-85C8-83720C9075D2/tmp/image_picker_330EC546-4007-4EDD-B411-316D165206A7-16637-0000225809C3E338.jpg
2020-04-15 11:06:06.986302-0500 Vitrix Health[16637:5310642] flutter: /private/var/mobile/Containers/Data/Application/DCD63FC0-340C-4B0F-85C8-83720C9075D2/tmp/image_picker_D6E97B42-ED47-42A5-948E-013D8BD5DA24-16637-000022583D577A2B.jpg
2020-04-15 11:06:07.087875-0500 Vitrix Health[16637:5310356] [LayoutConstraints] Unable to simultaneously satisfy constraints.
Probably at least one of the constraints in the following list is one you don't want.
Try this:
(1) look at each constraint and try to figure out which you don't expect;
(2) find the code that added the unwanted constraint or constraints and fix it.
(
"<NSLayoutConstraint:0x283df7ca0 LPLinkView:0x117e76690.leading == UILayoutGuide:0x2827e8ee0'UIViewLayoutMarginsGuide'.leading (active)>",
"<NSLayoutConstraint:0x283df7570 H:[LPLinkView:0x117e76690]-(59)-| (active, names: '|':_UIActivityContentTitleView:0x117ee8860 )>",
"<NSLayoutConstraint:0x283de2710 H:|-(0)-[_UIActivityContentTitleView:0x117ee8860] (active, names: '|':_UINavigationBarContentView:0x117ed4b10 )>",
"<NSLayoutConstraint:0x283de1810 _UIActivityContentTitleView:0x117ee8860.trailing == _UINavigationBarContentView:0x117ed4b10.trailing (active)>",
"<NSLayoutConstraint:0x283d8fac0 'UIView-Encapsulated-Layout-Width' _UINavigationBarContentView:0x117ed4b10.width == 0 (active)>",
"<NSLayoutConstraint:0x283df5220 'UIView-leftMargin-guide-constraint' H:|-(16)-UILayoutGuide:0x2827e8ee0'UIViewLayoutMarginsGuide' (active, names: '|':_UIActivityContentTitleView:0x117ee8860 )>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x283df7ca0 LPLinkView:0x117e76690.leading == UILayoutGuide:0x2827e8ee0'UIViewLayoutMarginsGuide'.leading (active)>
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.`
Is there a fix on the way for this?
I'm trying to use this plugin in a project where I share an image to email, but I can't do it just yet. When I enable the plugin, the project won't build for iOS. I get this output:
- `esys_flutter_share` does not specify a Swift version and none of the targets (`Runner`) integrating it have the `SWIFT_VERSION` attribute set. Please contact the author or set the `SWIFT_VERSION` attribute in at least one of the targets that integrate this pod.
I am using esys_flutter_share 1.0.1
and when I was building for iOS, the error was thrown.
Console shows
Running pod install...
CocoaPods' output:
↳
Preparing
Analyzing dependencies
Inspecting targets to integrate
Using `ARCHS` setting to build architectures of target `Pods-Runner`: (``)
Finding Podfile changes
A esys_flutter_share
R share
- Firebase
- Flutter
- cloud_firestore
- connectivity
- firebase_admob
- firebase_core
- google_sign_in
- package_info
- path_provider
- qrcode_reader
- shared_preferences
- sqflite
- url_launcher
Fetching external sources
-> Fetching podspec for `Flutter` from `.symlinks/flutter/ios`
-> Fetching podspec for `cloud_firestore` from `.symlinks/plugins/cloud_firestore/ios`
-> Fetching podspec for `connectivity` from `.symlinks/plugins/connectivity/ios`
-> Fetching podspec for `esys_flutter_share` from `.symlinks/plugins/esys_flutter_share/ios`
-> Fetching podspec for `firebase_admob` from `.symlinks/plugins/firebase_admob/ios`
-> Fetching podspec for `firebase_core` from `.symlinks/plugins/firebase_core/ios`
-> Fetching podspec for `google_sign_in` from `.symlinks/plugins/google_sign_in/ios`
-> Fetching podspec for `package_info` from `.symlinks/plugins/package_info/ios`
-> Fetching podspec for `path_provider` from `.symlinks/plugins/path_provider/ios`
-> Fetching podspec for `qrcode_reader` from `.symlinks/plugins/qrcode_reader/ios`
-> Fetching podspec for `shared_preferences` from `.symlinks/plugins/shared_preferences/ios`
-> Fetching podspec for `sqflite` from `.symlinks/plugins/sqflite/ios`
-> Fetching podspec for `url_launcher` from `.symlinks/plugins/url_launcher/ios`
Resolving dependencies of `Podfile`
Comparing resolved specification to the sandbox manifest
A BoringSSL-GRPC
A FMDB
A Firebase
A FirebaseAnalytics
A FirebaseAuth
A FirebaseAuthInterop
A FirebaseCore
A FirebaseDatabase
A FirebaseFirestore
A FirebaseInstanceID
A Flutter
A GTMSessionFetcher
A Google-Mobile-Ads-SDK
A GoogleAppMeasurement
A GoogleSignIn
A GoogleToolboxForMac
A GoogleUtilities
A Protobuf
A Reachability
A cloud_firestore
A connectivity
A esys_flutter_share
A firebase_admob
A firebase_core
A gRPC-C++
A gRPC-Core
A google_sign_in
A leveldb-library
A nanopb
A package_info
A path_provider
A qrcode_reader
A shared_preferences
A sqflite
A url_launcher
Downloading dependencies
-> Installing BoringSSL-GRPC (0.0.2)
> Copying BoringSSL-GRPC from `/Users/george/Library/Caches/CocoaPods/Pods/Release/BoringSSL-GRPC/0.0.2-2a230` to `Pods/BoringSSL-GRPC`
-> Installing FMDB (2.7.5)
> Copying FMDB from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FMDB/2.7.5-2ce00` to `Pods/FMDB`
-> Installing Firebase (5.17.0)
> Copying Firebase from `/Users/george/Library/Caches/CocoaPods/Pods/Release/Firebase/5.17.0-59d55` to `Pods/Firebase`
-> Installing FirebaseAnalytics (5.6.0)
> Copying FirebaseAnalytics from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FirebaseAnalytics/5.6.0-75e4b` to `Pods/FirebaseAnalytics`
-> Installing FirebaseAuth (5.3.1)
> Copying FirebaseAuth from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FirebaseAuth/5.3.1-0f61e` to `Pods/FirebaseAuth`
-> Installing FirebaseAuthInterop (1.0.0)
> Copying FirebaseAuthInterop from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FirebaseAuthInterop/1.0.0-0ffa5` to `Pods/FirebaseAuthInterop`
-> Installing FirebaseCore (5.3.0)
> Copying FirebaseCore from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FirebaseCore/5.3.0-c0c4b` to `Pods/FirebaseCore`
-> Installing FirebaseDatabase (5.1.0)
> Copying FirebaseDatabase from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FirebaseDatabase/5.1.0-23acb` to `Pods/FirebaseDatabase`
-> Installing FirebaseFirestore (1.0.1)
> Copying FirebaseFirestore from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FirebaseFirestore/1.0.1-e95af` to `Pods/FirebaseFirestore`
-> Installing FirebaseInstanceID (3.5.0)
> Copying FirebaseInstanceID from `/Users/george/Library/Caches/CocoaPods/Pods/Release/FirebaseInstanceID/3.5.0-4522a` to `Pods/FirebaseInstanceID`
-> Installing Flutter (1.0.0)
-> Installing GTMSessionFetcher (1.2.1)
> Copying GTMSessionFetcher from `/Users/george/Library/Caches/CocoaPods/Pods/Release/GTMSessionFetcher/1.2.1-32aec` to `Pods/GTMSessionFetcher`
-> Installing Google-Mobile-Ads-SDK (7.40.0)
> Copying Google-Mobile-Ads-SDK from `/Users/george/Library/Caches/CocoaPods/Pods/Release/Google-Mobile-Ads-SDK/7.40.0-9d1c3` to `Pods/Google-Mobile-Ads-SDK`
-> Installing GoogleAppMeasurement (5.6.0)
> Copying GoogleAppMeasurement from `/Users/george/Library/Caches/CocoaPods/Pods/Release/GoogleAppMeasurement/5.6.0-008e0` to `Pods/GoogleAppMeasurement`
-> Installing GoogleSignIn (4.4.0)
> Copying GoogleSignIn from `/Users/george/Library/Caches/CocoaPods/Pods/Release/GoogleSignIn/4.4.0-7ff24` to `Pods/GoogleSignIn`
-> Installing GoogleToolboxForMac (2.2.0)
> Copying GoogleToolboxForMac from `/Users/george/Library/Caches/CocoaPods/Pods/Release/GoogleToolboxForMac/2.2.0-ff316` to `Pods/GoogleToolboxForMac`
-> Installing GoogleUtilities (5.3.7)
> Copying GoogleUtilities from `/Users/george/Library/Caches/CocoaPods/Pods/Release/GoogleUtilities/5.3.7-111a0` to `Pods/GoogleUtilities`
-> Installing Protobuf (3.6.1)
> Copying Protobuf from `/Users/george/Library/Caches/CocoaPods/Pods/Release/Protobuf/3.6.1-1eb97` to `Pods/Protobuf`
-> Installing Reachability (3.2)
> Copying Reachability from `/Users/george/Library/Caches/CocoaPods/Pods/Release/Reachability/3.2-33e18` to `Pods/Reachability`
-> Installing cloud_firestore (0.0.1)
-> Installing connectivity (0.0.1)
-> Installing esys_flutter_share (0.0.1)
-> Installing firebase_admob (0.0.1)
-> Installing firebase_core (0.0.1)
-> Installing gRPC-C++ (0.0.6)
> Copying gRPC-C++ from `/Users/george/Library/Caches/CocoaPods/Pods/Release/gRPC-C++/0.0.6-e7644` to `Pods/gRPC-C++`
-> Installing gRPC-Core (1.17.0)
> Copying gRPC-Core from `/Users/george/Library/Caches/CocoaPods/Pods/Release/gRPC-Core/1.17.0-40280` to `Pods/gRPC-Core`
-> Installing google_sign_in (0.0.1)
-> Installing leveldb-library (1.20)
> Copying leveldb-library from `/Users/george/Library/Caches/CocoaPods/Pods/Release/leveldb-library/1.20-08cba` to `Pods/leveldb-library`
-> Installing nanopb (0.3.901)
> Copying nanopb from `/Users/george/Library/Caches/CocoaPods/Pods/Release/nanopb/0.3.901-2901f` to `Pods/nanopb`
-> Installing package_info (0.0.1)
-> Installing path_provider (0.0.1)
-> Installing qrcode_reader (0.0.1)
-> Installing shared_preferences (0.0.1)
-> Installing sqflite (0.0.1)
-> Installing url_launcher (0.0.1)
- Running pre install hooks
[!] Unable to determine Swift version for the following pods:
- `esys_flutter_share` does not specify a Swift version and none of the targets (`Runner`) integrating it have the `SWIFT_VERSION` attribute set. Please contact the author or set the `SWIFT_VERSION` attribute in at least one of the targets that integrate this pod.
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/cocoapods-1.6.1/lib/cocoapods/installer/xcode/target_validator.rb:115:in `verify_swift_pods_swift_version'
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/cocoapods-1.6.1/lib/cocoapods/installer/xcode/target_validator.rb:37:in `validate!'
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:459:in `validate_targets'
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:138:in `install!'
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/cocoapods-1.6.1/lib/cocoapods/command/install.rb:48:in `run'
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/claide-1.0.2/lib/claide/command.rb:334:in `run'
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/cocoapods-1.6.1/lib/cocoapods/command.rb:52:in `run'
/usr/local/Cellar/cocoapods/1.6.1/libexec/gems/cocoapods-1.6.1/bin/pod:55:in `<top (required)>'
/usr/local/Cellar/cocoapods/1.6.1/libexec/bin/pod:22:in `load'
/usr/local/Cellar/cocoapods/1.6.1/libexec/bin/pod:22:in `<main>'
Error output from CocoaPods:
↳
[!] Automatically assigning platform `ios` with version `8.0` on target `Runner` because no platform was specified. Please specify a platform for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.
Error running pod install
Error launching application on iPhone Xʀ.```
Instagram sharing now working on my app.
Working fine on all platform.
It is showing "Unable to process video" event thought my sharable content is image.
here is my code.
` static Future shareMedia({String url, String type = 'image'}) async {
File file = File(url);
var newFile = basename(file.path);
var newFileName = basenameWithoutExtension(file.path);
var type = "video/mp4";
if (type == 'image') {
type = 'image/jpg';
}
//
var request = await HttpClient().getUrl(
Uri.parse(url),
);
var response = await request.close();
Uint8List bytes = await consolidateHttpClientResponseBytes(response);
//
await Share.file(
newFileName,
newFile,
bytes,
type,
text: AppConfig.msg + '\n' + AppConfig.appUrl,
);
}`
Am I doing something wrong???
When I try to insert this plugin, I am getting this error:
Note: /Users/mac/flutter/.pub-cache/hosted/pub.dartlang.org/esys_flutter_share-0.0.6/android/src/main/java/de/esys/esysfluttershare/EsysFlutterSharePlugin.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
D8: Program type already present: android.support.v4.app.FrameMetricsAggregatorFAILURE: Build failed with an exception.
Currently sharing with pluging just displays image on facebook,instagram
image with text works with Whatsapp.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.