[android-developers] How does WebView handle content:// urls internally?

2011-09-19 Thread Jeff Thorn
Internally, how does WebView handle content:// urls? Does it use something like ContentResolver.openInputStream()? I tried looking at WebView source code and it appears that loadUrl eventually just calls the native webkit loadUrl method. So how does it resolve data from a content provider?

Re: [android-developers] Change Default Package Name of R.java

2010-06-15 Thread Jeff Thorn
I looked into Library Projects, but I am not sure if that helps me. I assume I would put the Activity in the library, since it is what is used by each app. However, that Activity relies on String values from res/values/strings. Each app will have different strings. Therefore the activity calls

Re: [android-developers] Re: Change Default Package Name of R.java

2010-06-15 Thread Jeff Thorn
15, 11:11 pm, Dianne Hackborn hack...@android.com wrote: The Froyo aapt will have a mechanism to build an existing package under a new name without modifying any of its source, manifest, or resources. On Tue, Jun 15, 2010 at 7:50 PM, Jeff Thorn jeff.th...@gmail.com wrote: I looked

Re: [android-developers] Change Default Package Name of R.java

2010-06-15 Thread Jeff Thorn
source, manifest, or resources. On Tue, Jun 15, 2010 at 7:50 PM, Jeff Thorn jeff.th...@gmail.com wrote: I looked into Library Projects, but I am not sure if that helps me. I assume I would put the Activity in the library, since it is what is used by each app. However, that Activity relies

Re: [android-developers] Change Default Package Name of R.java

2010-06-15 Thread Jeff Thorn
Looks like I need to use the --custom-package parameter. Hope this helps someone else out there. On Tue, Jun 15, 2010 at 11:55 PM, Jeff Thorn jeff.th...@gmail.com wrote: Hi Dianne, Can you clarify what that mechanism is? I tried adding the last to lines to the and target that generates

Re: [android-developers] Handling Orientation Changes that occur in another Activity

2010-06-03 Thread Jeff Thorn
Hi Rajiv, What changes should I make? I am saving the state in onSaveInstanceState and I am restoring the state in onCreate. I would think that the Bundle I saved the state to should preserve all the WebView settings, but that does not appear to be the case. Jeff On Thu, Jun 3, 2010 at 9:19 AM,

Re: [android-developers] Handling Orientation Changes that occur in another Activity

2010-06-03 Thread Jeff Thorn
of the Browser say browser //set Content to the Browser } Regards, Rajiv On Thu, Jun 3, 2010 at 6:54 PM, Jeff Thorn jeff.th...@gmail.com wrote: Hi Rajiv, What changes should I make? I am saving the state in onSaveInstanceState and I am restoring the state in onCreate. I would think that the Bundle

Re: [android-developers] Re: Handling Orientation Changes that occur in another Activity

2010-06-03 Thread Jeff Thorn
I have not defined these settings. I just want the WebView to fill the entire screen. Until the camera is launched, the default layout and scaling settings work just fine. It looks like somewhere the Scale setting gets changed from 1.5 to 1.0 after I call WebView.restoreState(). I don't want to

Re: [android-developers] Re: Avoid restarting background threads on orientation change

2010-05-20 Thread Jeff Thorn
As always, thanks Mark! I definitely see your point - its better to do short chunks of work in an AsyncTask than creating long running background threads. My app makes a lot of http requests. After the download is complete, it updates a database. I thought it would be better to create a single

Re: [android-developers] Re: Avoid restarting background threads on orientation change

2010-05-20 Thread Jeff Thorn
I took your advice and refactored my code to replace any long living background threads with AsyncTasks. Wow!!! I cannot begin to tell you how much it simplified my code. Thank you so much for the very valuable advice. On Thu, May 20, 2010 at 10:17 AM, Mark Murphy mmur...@commonsware.comwrote:

Re: [android-developers] Re: Clarification on loading local images with WebView

2010-05-13 Thread Jeff Thorn
Regarding option 1 - if I create a content provider it appears I need to implement the openFile method and return a ParcelFileDescriptor. Sounds easy enough. But how do you create a File object from something in the assets directory? On May 13, 2010 4:12 PM, Mark Murphy mmur...@commonsware.com

Re: [android-developers] Re: Clarification on loading local images with WebView

2010-05-13 Thread Jeff Thorn
. On May 13, 2010 6:51 PM, Mark Murphy mmur...@commonsware.com wrote: Jeff Thorn wrote: Regarding option 1 - if I create a content provider it appears I need to imple... Perhaps use openAssetFile() instead? -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http

Re: [android-developers] Re: Clarification on loading local images with WebView

2010-05-13 Thread Jeff Thorn
PS - meant something OTHER than. Droid autospell. :) On May 13, 2010 7:18 PM, Jeff Thorn jeff.th...@gmail.com wrote: You would think huh? But I got the impression for the docs that that method just allows you return a file segment using an offset and length. Can you do something like: File f

Re: [android-developers] Re: Clarification on loading local images with WebView

2010-05-13 Thread Jeff Thorn
I appreciate your help. I think I will just open the large image in a new custom Activity. On May 13, 2010 7:38 PM, Mark Murphy mmur...@commonsware.com wrote: Jeff Thorn wrote: PS - meant something OTHER than. Droid autospell. :) On May 13, 2010 7:18 P... mailto:jeff.th...@gmail.com wrote

Re: [android-developers] force WebView to wait for images

2010-04-23 Thread Jeff Thorn
Thanks Mark. Strange - I didn't get your response yesterday. I also didn't see the post ever appear on the discussion list. Thanks for answering it twice! On Fri, Apr 23, 2010 at 12:10 PM, Mark Murphy mmur...@commonsware.comwrote: Jeff wrote: When loading a page with WebView, images seem

Re: [android-developers] BUG in SQLite? Cannot use Long Integers in Cache Database

2010-04-13 Thread Jeff Thorn
I spent 2 days trying to figure this out, and wouldn't you know it...2 minutes after posting to the group, I think I have figured out what I was doing wrong. In order to check my work, I was exporting the database to my local computer and opening it with SQLite Administrator. The values were