alanlopes4 / stagewebviewbridge

Automatically exported from code.google.com/p/stagewebviewbridge
0 stars 1 forks source link

appfile protocol does not open file inside subfolder #24

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a index.html file inside the www folder
2. Create a folder inside the www folder and create an image inside it
3. Reference that image in the index.html using the appfile protocol, like 
this: <img src="appfile:/my_folder/image.jpg">

What is the expected output? What do you see instead?
The image to be drawn inside the html file

What version of the product are you using? On what operating system?
Version 1.0 Beta 3

Please provide any additional information below.
applink works for html inside sub-folders, just the appfile that does not.

Original issue reported on code.google.com by naftali....@gmail.com on 9 Mar 2012 at 2:35

GoogleCodeExporter commented 8 years ago
I managed to discover why this problem happens.

The following line from StageWebViewDisk.as does not consider subfolders when 
copying to the temp directory (wwwSource)

fileList[e].copyTo( _appCacheFile.resolvePath( _document_source + '/' + 
fileList[e].name ), true );

Original comment by naftali....@gmail.com on 9 Mar 2012 at 8:21

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I checked out the source here and managed to solve this problem. I am sending 
the patched version of the StageWebViewDisk

Original comment by naftali....@gmail.com on 9 Mar 2012 at 9:42

Attachments: