mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-07-24 19:24:45 +08:00
@ -14,6 +14,7 @@
|
||||
- text: "Git Remote Settings: Expose the git host"
|
||||
bugs:
|
||||
- text: "Fix notes not always showing up - #270"
|
||||
- text: "Fix sharing to GitJournal - #293"
|
||||
|
||||
- version: "1.71"
|
||||
date: 2020-10-12
|
||||
|
20
lib/app.dart
20
lib/app.dart
@ -226,9 +226,7 @@ class _JournalAppState extends State<JournalApp> {
|
||||
if (value == null) return;
|
||||
Log.d("Received Share $value");
|
||||
|
||||
setState(() {
|
||||
_sharedImages = value.map((f) => f.path)?.toList();
|
||||
});
|
||||
_sharedImages = value.map((f) => f.path)?.toList();
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) => handleShare());
|
||||
}, onError: (err) {
|
||||
Log.e("getIntentDataStream error: $err");
|
||||
@ -237,11 +235,9 @@ class _JournalAppState extends State<JournalApp> {
|
||||
// For sharing images coming from outside the app while the app is closed
|
||||
ReceiveSharingIntent.getInitialMedia().then((List<SharedMediaFile> value) {
|
||||
if (value == null) return;
|
||||
Log.d("Received Share with App running $value");
|
||||
Log.d("Received Share with App (media): $value");
|
||||
|
||||
setState(() {
|
||||
_sharedImages = value.map((f) => f.path)?.toList();
|
||||
});
|
||||
_sharedImages = value.map((f) => f.path)?.toList();
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) => handleShare());
|
||||
});
|
||||
|
||||
@ -249,9 +245,7 @@ class _JournalAppState extends State<JournalApp> {
|
||||
_intentDataStreamSubscription =
|
||||
ReceiveSharingIntent.getTextStream().listen((String value) {
|
||||
Log.d("Received Share $value");
|
||||
setState(() {
|
||||
_sharedText = value;
|
||||
});
|
||||
_sharedText = value;
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) => handleShare());
|
||||
}, onError: (err) {
|
||||
Log.e("getLinkStream error: $err");
|
||||
@ -259,10 +253,8 @@ class _JournalAppState extends State<JournalApp> {
|
||||
|
||||
// For sharing or opening text coming from outside the app while the app is closed
|
||||
ReceiveSharingIntent.getInitialText().then((String value) {
|
||||
Log.d("Received Share with App running $value");
|
||||
setState(() {
|
||||
_sharedText = value;
|
||||
});
|
||||
Log.d("Received Share with App (text): $value");
|
||||
_sharedText = value;
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) => handleShare());
|
||||
});
|
||||
}
|
||||
|
@ -115,9 +115,6 @@ class AppRouter {
|
||||
|
||||
var rootFolder = repository.notesFolder;
|
||||
|
||||
sharedText = null;
|
||||
sharedImages = null;
|
||||
|
||||
Log.d("sharedText: $sharedText");
|
||||
Log.d("sharedImages: $sharedImages");
|
||||
|
||||
|
Reference in New Issue
Block a user