From: <D.D...@ak...> - 2011-05-12 08:57:56
|
<font face="Default Sans Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><div>Hi all,<br><br>Just to let you know how I solved my issue, in case you need it too:<br><br>1) To address the path of the resources folder, I use<br> <br> <font><font face="Default Sans Serif,Verdana,Arial,Helvetica,sans-serif" size="2">NSBunde.mainBundle.bundlePath</font></font><br> <br> this returns the path of my .app package, containing all the necessary files for the application. It works <br> like a charm on both the simulator and the device, I tried it on different machines too.<br><br>2) The append of the "/res/" (or whatever the resources folder is called) to the previous depends, if I well understood,<br> on the way I configure the xmlvm.resource option. That is, if I set it to be "res/", then the .app file<br> will contain a folder named res totally equivalent to the original one. If I set it to be "res", then the subfolders and files<br> contained in it will be directly copied in the .app package. Thus, I don't need to add the "/res/" part to the path<br> when addressing files.<br><br>3) It is possible to set the xmlvm.resource property both whil creating the project, through the --resource argument,<br> or by setting the xmlvm.resource entry in the xmlvm.properties file of an existing project.<br><br>4) I don't need to specify the bundlePath if I want to load images through the UIImage class. In that case, I only need<br> the path starting from the bundlePath (e.g: "res/myImages/file.jpg" or "myImages/file.jpg depending on the cases discussed above).<br><br>Hope this helps!<br><br>Domenico<br><br><br><br></div><font color="#990099">-----Transféré par Dominico DE FANO/FR/AKKA le 12/05/2011 10:12 -----<br><br></font><blockquote style="padding-right:0px;padding-left:5px;margin-left:5px;border-left:#000000 2px solid;margin-right:0px">A : Panayotis Katsaloulis <a class="moz-txt-link-rfc2396E" href="mailto:pan...@pa..."><pan...@pa...></a><br>De : Dominico DE FANO/FR/AKKA<br>Date : 10/05/2011 12:33<br>Objet : Re: [xmlvm-users] [xmlvm-dev] Files path<br><br><font face="Default Sans Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><div>Hi,<br><br>That is exactly what I wanted to try, to see what happens by removing the "/".<br>But nothing happened, and the app worked as usual.<br><br><br></div><font color="#990099">-----Panayotis Katsaloulis <a class="moz-txt-link-rfc2396E" href="mailto:pan...@pa..."><pan...@pa...></a> a écrit : -----<br><br></font><blockquote style="padding-right:0px;padding-left:5px;margin-left:5px;border-left:#000000 2px solid;margin-right:0px">A : XMLVM User <a class="moz-txt-link-rfc2396E" href="mailto:xml...@li..."><xml...@li...></a><br>De : Panayotis Katsaloulis <a class="moz-txt-link-rfc2396E" href="mailto:pan...@pa..."><pan...@pa...></a><br>Date : 10/05/2011 12:20<br>Objet : Re: [xmlvm-users] [xmlvm-dev] Files path<br><br><br><div><div>On 10 Μαϊ 2011, at 12:50 μ.μ., <a href="mailto:D.D...@ak...">D.D...@ak...</a> wrote:</div><br><blockquote type="cite"><font face="Default Sans Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><div>If I check the project, I have a resources folder that only contains the demo.png file, while<br>the xmlvm.properties file has the entry<br><br>xmlvm.resource=resources/ <br><br>Obviously it didn't take into account my resources. How should it behave instead? <br>Should it copy my files into the resources/ folder? Can I do it manually?<br>That's what I did previously and it works, as far as I use images. If I try to read a file<br>instead, I get the error I wrote you about. I don't know if the things are connected.<br>It may be useful to know that mu res/ folder contains subdirectories which contain the needed files<br><br>I also tried to modify the resource path to <br><br>xmlvm.resource=res<br><br></div></font></blockquote><div><br></div><div><br></div><div>Notice, one entry has a "/" and the other has not.</div><div>If you see the help file of xmlvm (or the online documentation), you'll see that the "/" is important at the end.</div><div><br></div></div><font face="Courier New,Courier,monospace" size="3">------------------------------------------------------------------------------<br>Achieve unprecedented app performance and reliability<br>What every C/C++ and Fortran developer should know.<br>Learn how Intel has extended the reach of its next-generation tools<br>to help boost performance applications - inlcuding clusters.<br><a href="http://p.sf.net/sfu/intel-dev2devmay">http://p.sf.net/sfu/intel-dev2devmay</a></font><font face="Courier New,Courier,monospace" size="3">_______________________________________________<br>xmlvm-users mailing list<br><a class="moz-txt-link-abbreviated" href="mailto:xml...@li...">xml...@li...</a><br><a href="https://lists.sourceforge.net/lists/listinfo/xmlvm-users">https://lists.sourceforge.net/lists/listinfo/xmlvm-users</a><br></font> </blockquote><br></font> </blockquote><br></font> |