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 7334F17E04 for ; Fri, 13 Feb 2015 17:33:30 +0000 (UTC) Received: (qmail 14240 invoked by uid 500); 13 Feb 2015 17:33:30 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 14201 invoked by uid 500); 13 Feb 2015 17:33:30 -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 14186 invoked by uid 99); 13 Feb 2015 17:33:29 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 13 Feb 2015 17:33:29 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of agrieve@google.com designates 209.85.213.173 as permitted sender) Received: from [209.85.213.173] (HELO mail-ig0-f173.google.com) (209.85.213.173) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 13 Feb 2015 17:33:05 +0000 Received: by mail-ig0-f173.google.com with SMTP id a13so12056678igq.0 for ; Fri, 13 Feb 2015 09:33:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=Eyp5hXb12wmdBJ7Syk4DPaoh2TVuoIfIZLkPoIpoPfU=; b=CuPPk7lYHmmeDcZ1sdhiVZ5gr1pW4zKJQJ/zedKLA5zbitC8ZM0A0Tsq/pB6ni6cRc iRbk/Z2Oorl99JGAGoAGoYX595Ksaej/melgzhAyr1rMIYXZpXc5yi1xawSmbVFb0B3C Rfn+tqMWmbQNYXjdCvm90iE+7hXlyeo8M0Va9uVq/JXVuMtWRvVzsL3PX6lliXKfEvom nf9M5kyVRi1AOg9S/BLLWmgeOVQAzigC5oVBDt5dqpoLw7U1cMA5d7esAq++GVO3jBNr WO65aQOhTcDfXx1V/HwF3+QYSicstaMPAY0Zlz5KZm3N/Fat8JVxLTGrsyzqMbCMYghT tLzw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=Eyp5hXb12wmdBJ7Syk4DPaoh2TVuoIfIZLkPoIpoPfU=; b=iQb5ZCy5woqmxyaNYNFOm3mMPqzT3t/43xWucxhAC/8+tVx5lMb4xEZD4gvrnCXEnq +Gp0e6RfNsNibg5hPPz4LFfpzQYhDnT4xv9STLsZzjY4ieoLAwJwRLzExzZ2OfYwJEt+ 6ekYqlYjCEC+gVPPt9e/LAheWBSs7O0MC91KE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:content-type; bh=Eyp5hXb12wmdBJ7Syk4DPaoh2TVuoIfIZLkPoIpoPfU=; b=IbPwgFcOyAfRFDayo2SdjrdbM1gIZUWNBOBAoKz4wmkIbftM4tjjvY1Ha6YztipZ1X QuLjhUfx2DEempS7GomCOJ62/z1shu11ACwSRvdqGTmYW5VdchhEdGk9g4akflKDnDu4 gkdE7VOHN0JoNbWcCfJoXXLc7gnLnerSJtVLBJrG3ytjiUFzJaxEhh/L5ZuOHpcbm8as pm8RQEZhraQgfYfrJs3A1Pdt7PZ2Kg9h05Q0MMHV22xBsJurfLqSJDY9Bof8RYdNRSI6 T6yFGeKAL4B6NE+O/kHtyIQyp0sNR6w+kf+zZJ4sKMTimQIEoLssP6Z/1RCxK9LBJCPS DTrg== X-Gm-Message-State: ALoCoQndkljLTbTgNjU8HxmH3GH8tAFe+ktsFiNgxF/5PfZ+b76D+N1uokaGA8aZVW0nP3Fk5J6s X-Received: by 10.50.109.228 with SMTP id hv4mr5138222igb.45.1423848783321; Fri, 13 Feb 2015 09:33:03 -0800 (PST) MIME-Version: 1.0 Sender: agrieve@google.com Received: by 10.36.3.136 with HTTP; Fri, 13 Feb 2015 09:32:43 -0800 (PST) In-Reply-To: References: From: Andrew Grieve Date: Fri, 13 Feb 2015 12:32:43 -0500 X-Google-Sender-Auth: ryZ44FX2gM3xj__OO03x5QfJVc4 Message-ID: Subject: Re: Maintaining App Data When Switching WebViews To: dev Content-Type: multipart/alternative; boundary=089e013a214ef1b49c050efba014 X-Virus-Checked: Checked by ClamAV on apache.org --089e013a214ef1b49c050efba014 Content-Type: text/plain; charset=UTF-8 Had a look. Seems WKWebView and UIWebView's storage files are compatible, so the plugin just copies the file to a new location. Obviously the easiest/best solution if it works (not intending to try myself though... any takers?) On Fri, Feb 13, 2015 at 11:04 AM, Ryan Hanna wrote: > Would the google drive persistence be useful across webviews for apps > already using storage that is not with google drive? > > Eddy V seems to have come up with a great solution for iOS in his WKWebview > plugin as a > reference. > https://github.com/Telerik-Verified-Plugins/WKWebView/commits/master?page=2 > > -Ryan Hanna > Sworkit Developer > > On Fri, Feb 13, 2015 at 6:28 AM, Jay Proulx wrote: > > > For iOS you can use the new shared keychain, and for android you can > > persist data to google drive to share across applications. > > > > https://github.com/googledrive/appdatapreferences-android > > > > > > Jay Proulx | computer scientist | aem engineering | office: 613.940.4052 > | > > mobile: 613 866 0732 | adobe systems > > > > > > > > > > On 2015-02-12, 4:05 PM, "Josh Bavari" wrote: > > > > >Andrew, > > > > > >Here at Ionic, we've had a few users request something like this. My > > >approach has been to create a Cordova plugin, that takes the following > > >steps: > > > > > >Creates an instance of the original webview > > >Executes some JS inside the webview that will grab all entries for > > >localstorage > > >If Android pre KIT_KAT or more, executed JS calls a JSInterface to pass > > >the > > >data back to native land > > >If KIT_KAT or greater, calls evaluateJavascript > > >Those values are read, and passed back to the original webview > > >From there, it'd go through the keys, and add them into the new webview > > > > > >See this repo for my work in progress: > > >https://github.com/driftyco/cordova-plugin-local-storage-retrieval > > > > > >On Thu, Feb 12, 2015 at 1:46 PM, Andrew Grieve > > >wrote: > > > > > >> Worth a discussion about this, I think. > > >> > > >> If you have an app already launched that uses localstorage/websql, and > > >>want > > >> to switch to xwalk, how can you migrate your data? > > >> > > >> What if you want to use system webview for API >= 21 and xwalk only > for > > >>old > > >> phones? Then you need to move data in the reverse direction. > > >> > > >> > > >> Idea 1: > > >> - See if sqlite / localstorage databases are the same format, and > > >>provide > > >> code that migrates db locations > > >> > > >> Idea 2: > > >> - Use wizcorp's multi-window plugin to create a new an off-screen > system > > >> webview, then use post-message to read data out of the old one. > > >> > > >> WDYT? Is this a problem we need to solve? > > >> > > > > > > > > > > > >-- > > >"Clear thoughts produce clear results." > > >Josh Bavari > > >Application Developer > > >Phone: 405-509-9448 > > >Cell: 405-812-0496 > > >Email: jbavari@gmail.com > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org > > For additional commands, e-mail: dev-help@cordova.apache.org > > > > > --089e013a214ef1b49c050efba014--