From 9de3b36b9a1c6cd1b759db7bc34d4172fddf667c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 21 Feb 2016 10:42:55 +0100 Subject: new 0100-ios8.patch --- debian/changelog | 9 ++++ debian/patches/0100-ios8.patch | 96 ++++++++++++++++++++++++++++++++++++++++++ debian/patches/series | 1 + 3 files changed, 106 insertions(+) create mode 100644 debian/patches/0100-ios8.patch (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index f77a267..8b1717f 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,12 @@ +shotwell (0.22.0-4) UNRELEASED; urgency=medium + + * New debian/patches/0100-ios8.patch (Closes: #792016): + - Quick and dirty patch to get iOS 8 devices ready to download files. + Downloade from https://bugzilla.gnome.org/show_bug.cgi?id=742295#c22. + Thanks to Obsidian. + + -- Jörg Frings-Fürst Sun, 21 Feb 2016 10:20:39 +0100 + shotwell (0.22.0-3) unstable; urgency=medium * debian/rules: diff --git a/debian/patches/0100-ios8.patch b/debian/patches/0100-ios8.patch new file mode 100644 index 0000000..c28066f --- /dev/null +++ b/debian/patches/0100-ios8.patch @@ -0,0 +1,96 @@ +Index: trunk/src/camera/ImportPage.vala +=================================================================== +--- trunk.orig/src/camera/ImportPage.vala ++++ trunk/src/camera/ImportPage.vala +@@ -766,6 +766,15 @@ public class ImportPage : CheckerboardPa + ~ImportPage() { + LibraryPhoto.global.contents_altered.disconnect(on_media_added_removed); + Video.global.contents_altered.disconnect(on_media_added_removed); ++ ++ // iOS 8 issue. Release the camera here ++ if (camera != null) { ++ GPhoto.Result res = camera.exit(spin_idle_context.context); ++ if (res != GPhoto.Result.OK) { ++ // log but don't fail ++ warning("ImportPage destructor: Unable to unlock camera: %s", res.to_full_string()); ++ } ++ } + } + + public override Gtk.Toolbar get_toolbar() { +@@ -1153,11 +1162,14 @@ public class ImportPage : CheckerboardPa + update_status(busy, false); + + refresh_error = null; +- refresh_result = camera.init(spin_idle_context.context); +- if (refresh_result != GPhoto.Result.OK) { +- warning("Unable to initialize camera: %s", refresh_result.to_full_string()); +- +- return (refresh_result == GPhoto.Result.IO_LOCK) ? RefreshResult.LOCKED : RefreshResult.LIBRARY_ERROR; ++ // iOS 8 issue ++ if (camera == null) { ++ refresh_result = camera.init(spin_idle_context.context); ++ if (refresh_result != GPhoto.Result.OK) { ++ warning("Unable to initialize camera: %s", refresh_result.to_full_string()); ++ ++ return (refresh_result == GPhoto.Result.IO_LOCK) ? RefreshResult.LOCKED : RefreshResult.LIBRARY_ERROR; ++ } + } + + update_status(true, refreshed); +@@ -1262,13 +1274,15 @@ public class ImportPage : CheckerboardPa + progress_bar.set_ellipsize(Pango.EllipsizeMode.NONE); + progress_bar.set_text(""); + progress_bar.set_fraction(0.0); +- ++ ++#if 0 + GPhoto.Result res = camera.exit(spin_idle_context.context); + if (res != GPhoto.Result.OK) { + // log but don't fail + warning("Unable to unlock camera: %s", res.to_full_string()); + } +- ++#endif ++ + if (refresh_result == GPhoto.Result.OK) { + update_status(false, true); + } else { +@@ -1634,11 +1648,15 @@ public class ImportPage : CheckerboardPa + } + + private void import(Gee.Iterable items) { +- GPhoto.Result res = camera.init(spin_idle_context.context); +- if (res != GPhoto.Result.OK) { +- AppWindow.error_message(_("Unable to lock camera: %s").printf(res.to_full_string())); +- +- return; ++ // We now keep the camera open as long as we can to ++ // work around the iOS 8 directory name shuffling issue. ++ if (camera == null) { ++ GPhoto.Result res = camera.init(spin_idle_context.context); ++ if (res != GPhoto.Result.OK) { ++ AppWindow.error_message(_("Unable to lock camera: %s").printf(res.to_full_string())); ++ ++ return; ++ } + } + + update_status(true, refreshed); +@@ -1774,12 +1792,15 @@ public class ImportPage : CheckerboardPa + } + + private void close_import() { ++// iOS 8 issue ++#if 0 + GPhoto.Result res = camera.exit(spin_idle_context.context); + if (res != GPhoto.Result.OK) { + // log but don't fail + message("Unable to unlock camera: %s", res.to_full_string()); + } +- ++#endif ++ + update_status(false, refreshed); + + on_view_changed(); diff --git a/debian/patches/series b/debian/patches/series index 07037ee..fe75c5e 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -5,3 +5,4 @@ 0501-Dont-pack-webview-into-a-scrolled-window.patch 0502-Have-all-soup-sessions-validate-TLS-certificates.patch 0503-facebook-Dont-disable-XSS-auditor.patch +0100-ios8.patch -- cgit v1.2.3