mirror of
https://github.com/immich-app/immich.git
synced 2025-06-23 15:30:51 -04:00
fix(mobile): correct share option for local asset (#19233)
This commit is contained in:
parent
c6641d4859
commit
06f1d0dc4d
@ -30,7 +30,7 @@ class ShareService {
|
|||||||
for (var asset in assets) {
|
for (var asset in assets) {
|
||||||
if (asset.isLocal) {
|
if (asset.isLocal) {
|
||||||
// Prefer local assets to share
|
// Prefer local assets to share
|
||||||
File? f = await asset.local!.file;
|
File? f = await asset.local!.originFile;
|
||||||
downloadedXFiles.add(XFile(f!.path));
|
downloadedXFiles.add(XFile(f!.path));
|
||||||
} else if (asset.isRemote) {
|
} else if (asset.isRemote) {
|
||||||
// Download remote asset otherwise
|
// Download remote asset otherwise
|
||||||
|
@ -131,15 +131,14 @@ class ControlBottomAppBar extends HookConsumerWidget {
|
|||||||
|
|
||||||
List<Widget> renderActionButtons() {
|
List<Widget> renderActionButtons() {
|
||||||
return [
|
return [
|
||||||
if (hasRemote)
|
ControlBoxButton(
|
||||||
ControlBoxButton(
|
iconData: Platform.isAndroid
|
||||||
iconData: Platform.isAndroid
|
? Icons.share_rounded
|
||||||
? Icons.share_rounded
|
: Icons.ios_share_rounded,
|
||||||
: Icons.ios_share_rounded,
|
label: "share".tr(),
|
||||||
label: "share".tr(),
|
onPressed: enabled ? () => onShare(true) : null,
|
||||||
onPressed: enabled ? () => onShare(true) : null,
|
),
|
||||||
),
|
if (!isInLockedView && hasRemote)
|
||||||
if (!isInLockedView)
|
|
||||||
ControlBoxButton(
|
ControlBoxButton(
|
||||||
iconData: Icons.link_rounded,
|
iconData: Icons.link_rounded,
|
||||||
label: "share_link".tr(),
|
label: "share_link".tr(),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user