<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
    <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/104450/">http://git.reviewboard.kde.org/r/104450/</a>
     </td>
    </tr>
   </table>
   <br />









<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/104450/diff/1/?file=55374#file55374line196" style="color: black; font-weight: bold; text-decoration: underline;">src/android/jar/src/org/kde/necessitas/industrius/QtNative.java</a>
    <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">public static boolean startApplication(String params, String environment)</pre></td>
   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">public static boolean startApplication(String params, String environment, String mainLibrary, String nativeLibraryDir) throws Exception</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">196</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">                <span class="nf">startQtApp</span><span class="o">(</span><span class="s">"QtApp"</span><span class="o">+</span><span class="n">params</span><span class="o">,</span> <span class="n">environment</span><span class="o">,</span> <span class="o">(</span><span class="n">f</span><span class="o">==</span><span class="kc">null</span><span class="o">)</span> <span class="o">?</span> <span class="kc">null</span> <span class="o">:</span> <span class="n">f</span><span class="o">.</span><span class="na">getAbsolutePath</span><span class="o">());</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Please change this line to                 startQtApp("QtApp"+params, environment, f.getAbsolutePath());

f==null is already checked.</pre>
</div>
<br />



<p>- BogDan</p>


<br />
<p>On March 31st, 2012, 10:08 p.m., Tyler Mandry wrote:</p>






<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
 <tr>
  <td>

<div>Review request for Necessitas and BogDan Vatra.</div>
<div>By Tyler Mandry.</div>


<p style="color: grey;"><i>Updated March 31, 2012, 10:08 p.m.</i></p>






<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Allows interaction between user Java and user C/C++ (JNI) code, by loading the user's code in the main class loader.
SF.net bug: 140

Details
-------
This removes everything in src/android/cpp. qtmain_android.cpp is no more and is now integrated into src/plugins/platforms/android/src/androidjnimain.cpp. It seemed fitting to integrate startQtApp() into the same file as pauseQtApp() and resumeQtApp(). (Additionally this removes redundant copied code, and simplifies how necessitas projects work and are built.)

Compatibility
-------------
New library should be fully compatible with apps *already built* with old versions (before this change.) To build against the new library, existing projects simply need to update their QtActivity.java file.

Other
-----
This doesn't support using JNI with bundled libs. We have to be careful to load certain bundled libs (maybe only the plugin .so) in the delegate class loader, so I could break certain apps by making such a switch. Need a way to categorize the type of bundled lib, in order to decide which class loader to use.</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Tested on a Galaxy Nexus and a Nexus One.
New libraries run both old and new apps.
New libraries support JNI interaction.</pre>
  </td>
 </tr>
</table>




<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>mkspecs/android-g++/qmake.conf <span style="color: grey">(ff30694)</span></li>

 <li>mkspecs/features/qt.prf <span style="color: grey">(a254437)</span></li>

 <li>src/android/cpp/qtmain_android.cpp <span style="color: grey">(e5f5fc8)</span></li>

 <li>src/android/jar/src/org/kde/necessitas/industrius/QtActivityDelegate.java <span style="color: grey">(85add90)</span></li>

 <li>src/android/jar/src/org/kde/necessitas/industrius/QtNative.java <span style="color: grey">(24ebb5b)</span></li>

 <li>src/android/java/src/org/kde/necessitas/origo/QtActivity.java <span style="color: grey">(fcbccef)</span></li>

 <li>src/plugins/platforms/android/src/androidjnimain.cpp <span style="color: grey">(20d7df5)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/104450/diff/" style="margin-left: 3em;">View Diff</a></p>




  </td>
 </tr>
</table>








  </div>
 </body>
</html>