Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9CF5718566 for ; Sat, 20 Feb 2016 23:25:28 +0000 (UTC) Received: (qmail 32801 invoked by uid 500); 20 Feb 2016 23:25:28 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 32760 invoked by uid 500); 20 Feb 2016 23:25:28 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 32747 invoked by uid 99); 20 Feb 2016 23:25:28 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 20 Feb 2016 23:25:28 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id A76CEC1EFC for ; Sat, 20 Feb 2016 23:25:27 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.179 X-Spam-Level: * X-Spam-Status: No, score=1.179 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id JjVZp1CJd5CC for ; Sat, 20 Feb 2016 23:25:26 +0000 (UTC) Received: from mail-qk0-f173.google.com (mail-qk0-f173.google.com [209.85.220.173]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id C0DDB5F1E7 for ; Sat, 20 Feb 2016 23:25:25 +0000 (UTC) Received: by mail-qk0-f173.google.com with SMTP id s68so43985901qkh.3 for ; Sat, 20 Feb 2016 15:25:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=ywKhwtqrSeHfO7SpW1yIqHxU1g06oowxtiGZsRswMrw=; b=JrFanZcr6k+DmXH3X+okmuZlJ/awPTAn3LOnA20dDq5325sJAiSRmvxx4lIRdQsN0r G0vgq0JxRdXMqTnlmFjZ4KpZqc48Y8bJCSu1JGBkDlwl74P1BILUkq88Zv40LMW913EF exg0WcuPkkhJ8oUehN/sIfMsE4E3Ajk6WM4UZ+5oj1ObFkMPN0zHUhr0sckCSfds5uUh R0LdM/gEmzGbNtHhsz/8EaSMRg0OQ6PZFiRx1XwuHJAfg+hpstqnrHuI0ZHHyY2dUNMG uSYze5A1H7itRV+HXYl2cyLFq/XbQX5UFiT0751UfoitOpLCjI9IwOdATGwXNuKdIY0L tphQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=ywKhwtqrSeHfO7SpW1yIqHxU1g06oowxtiGZsRswMrw=; b=KDkuXJ61j2B/dIUE1zeohUBAQyiWrzI5hHkrLU/zXE1GOW7kUH6bkNhYGzmZH/+q2g IPIg2gkinFfCjCLZ0AGMQczqrDxOiufVOz+LxDf92OCiy7FdwwkM48oigyXP0YqBt9w7 pZ3C3iXL9Eg1dgBtxgRqAAmIFo8kGH/mywXTVQn3YvInkaIxyfRjzCCoZIHQfVrgh+zy US6l33RutEj72u7Rawj2GkLhGwkWQIpDNXiCTX4Vsi3pzbSUlzZa7soAiR2x3cTAGfWB pO9vP/rVi3GuAhEg8Y4hInP4KWPGtOK+YwJpUpKk002g/aXITpis4tKqAUM9z3s4HM+u YMSQ== X-Gm-Message-State: AG10YORwOejUlXbYzTgSdcn5FnknpLCDzQNBX0tw4IWGzVBZwOiq/WaaVHC4GKgz+eyqu3ZFV2gtUp4wa1Jpag== MIME-Version: 1.0 X-Received: by 10.55.71.135 with SMTP id u129mr25996129qka.26.1456010418823; Sat, 20 Feb 2016 15:20:18 -0800 (PST) Received: by 10.140.105.53 with HTTP; Sat, 20 Feb 2016 15:20:18 -0800 (PST) In-Reply-To: References: Date: Sun, 21 Feb 2016 00:20:18 +0100 Message-ID: Subject: Re: [Android] CB-10625 Google Photos update breaks Camera's Gallery API From: julio cesar sanchez To: "dev@cordova.apache.org" Content-Type: multipart/alternative; boundary=001a114a7d20cda98e052c3bd731 --001a114a7d20cda98e052c3bd731 Content-Type: text/plain; charset=UTF-8 Bad news, I tried at home and didn't work on android 4.4 or android 5, it's not entering on the isGooglePhotosUri and always goes to the error callback. Trying to force the uri.getLastPathSegment() doesn't return a good url neither. I'm not sure why it worked when I tested on android M, will check again on monday. 2016-02-19 8:22 GMT+01:00 julio cesar sanchez : > Sure, I can send it this weekend. > > 2016-02-18 18:49 GMT+01:00 Joe Bowser : > >> Cool, want to send a PR so we can get this resolved? I tried string >> manipulation, but for some reason it didn't work. >> >> On Thu, Feb 18, 2016 at 1:22 AM, julio cesar sanchez < >> jcesarmobile@gmail.com >> > wrote: >> >> > I already answered on CB-10625 >> > >> > When android 4.4 broke input type file support I wrote a plugin at work >> to >> > use a file picker instead. >> > >> > For google Photos I use this code: >> > >> > if (isGooglePhotosUri(uri)) >> > return uri.getLastPathSegment(); >> > >> > Where isGooglePhotosUri is >> > >> > public static boolean isGooglePhotosUri(Uri uri) { >> > return >> > "com.google.android.apps.photos.content".equals(uri.getAuthority()); >> > } >> > >> > I tried it on the camera plugin and worked. >> > >> > >> > The plugin is based on this android library >> > https://github.com/iPaulPro/aFileChooser >> > >> > The relevant class is >> > >> > >> https://github.com/iPaulPro/aFileChooser/blob/master/aFileChooser/src/com/ipaulpro/afilechooser/utils/FileUtils.java >> > >> > >> > >> > >> > 2016-02-17 1:41 GMT+01:00 Joe Bowser : >> > >> > > Hey >> > > >> > > https://issues.apache.org/jira/browse/CB-10625 >> > > >> > > For some reason Google Photos breaks the Camera's Gallery API, and I'm >> > > having trouble trying to fix this one. For some reason I can't get >> the >> > > FileHelper to work with the new file URI that's being provided by an >> > > application. Is there something obvious that we're missing here? >> > > >> > > Any thoughts? >> > > >> > >> > > --001a114a7d20cda98e052c3bd731--