<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Problems on android in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/problems-on-android/m-p/561552#M52427</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;If you have a support contract with Esri you can file a bug report at &lt;A href="http://support.esri.com"&gt;http://support.esri.com&lt;/A&gt;.&amp;nbsp; As far as I know that is the only way to file a bug report, but the JS API devs do read this forum.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Ok, thanks. I'll wait for a dev to come around then.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 02 May 2013 06:08:01 GMT</pubDate>
    <dc:creator>ThomasCoopman</dc:creator>
    <dc:date>2013-05-02T06:08:01Z</dc:date>
    <item>
      <title>Problems on android</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/problems-on-android/m-p/561550#M52425</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have a problem with the ArcGIS Javascript API on android. (it could be linked with the problem I described&amp;nbsp; in a previous post (see &lt;/SPAN&gt;&lt;A href="http://forums.arcgis.com/threads/82287-Hiding-the-map-problems-with-building-a-mobile-application-with-AngularJS?p=290084#post290084" rel="nofollow noopener noreferrer" target="_blank"&gt;here&lt;/A&gt;&lt;SPAN&gt;) but I don't believe this is the case, however I'm not sure so I'm linking the issue)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The problem occurs on android 4.2.2 with the Chrome browser.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;After some navigation interaction (pinching, swiping, dragging,...) with the map I sometimes get the following error: &lt;/SPAN&gt;&lt;SPAN style="font-style:italic;"&gt;Uncaught TypeError: Cannot read property 'identifier' of undefined &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It's rather hard to debug the minified javascript code so I formatted it (&lt;/SPAN&gt;&lt;A href="http://jsbeautifier.org/" rel="nofollow noopener noreferrer" target="_blank"&gt;http://jsbeautifier.org/&lt;/A&gt;&lt;SPAN&gt;) and ran it through a debugger to find out what the problem was. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the function _touchMove:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
 if (this._numTouches === 2) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; var _ba1 = this._nodeTouches[0],
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _ba2 = this._nodeTouches[1];
&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!this._pinchActive) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (_b9f) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var _ba3 = _b9d[_ba1.identifier],
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _ba4 = _b9d[_ba2.identifier],
 ....
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The error is on the line _ba4 = _b9d[_ba2.identifier]. &lt;/SPAN&gt;&lt;SPAN style="font-style:italic;"&gt;Uncaught TypeError: Cannot read property 'identifier' of undefined &lt;/SPAN&gt;&lt;SPAN&gt; and undifend is _ba2. The problem is that this._numTouches === 2 &lt;/SPAN&gt;&lt;STRONG&gt;but &lt;/STRONG&gt;&lt;SPAN&gt;_this._nodeTouches.length === 1&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;After debugging some more I found out that the problem must be with the _addTouch and _removeTouch method. I believe that _removeTouch is not always called but It's hard to confirm this. I've detected this by logging _this.numTouches. The behaviour I got was that touching with multiple fingers (more then 3 for example) and then lifting them again, _this.numTouches didn't always go down to 0.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As a fix for my own, I did this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
_addTouch: function (_bc4) {
&amp;nbsp; var i, _bc5 = _bc4.changedTouches,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _bc6 = this._nodeTouches;
&amp;nbsp; this._numTouches = _bc4.touches.length;
&amp;nbsp; //this._numTouches += _bc5.length;
&amp;nbsp; ...
}
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So instead of using _bc4.changedTouches.length I use _bc4.touches.length (likewise in _removeTouch). Are there any reasons changedTouches is used instead of touches?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Some follow up questions:&lt;/SPAN&gt;&lt;BR /&gt;&lt;UL&gt;&lt;BR /&gt;&lt;LI&gt; Is there any chance you will post your de-uglified API online? Maybe even make the API available on github?&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt; Is this forum the right place to ask these kind of questions? This looks like a bug to me.&lt;/LI&gt;&lt;BR /&gt;&lt;/UL&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 00:13:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/problems-on-android/m-p/561550#M52425</guid>
      <dc:creator>ThomasCoopman</dc:creator>
      <dc:date>2021-12-12T00:13:34Z</dc:date>
    </item>
    <item>
      <title>Re: Problems on android</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/problems-on-android/m-p/561551#M52426</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Is this forum the right place to ask these kind of questions? This looks like a bug to me.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Yes, this would seem to be the right place to ask.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you have a support contract with Esri you can file a bug report at &lt;/SPAN&gt;&lt;A href="http://support.esri.com"&gt;http://support.esri.com&lt;/A&gt;&lt;SPAN&gt;.&amp;nbsp; As far as I know that is the only way to file a bug report, but the JS API devs do read this forum.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 30 Apr 2013 15:23:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/problems-on-android/m-p/561551#M52426</guid>
      <dc:creator>JeffJacobson</dc:creator>
      <dc:date>2013-04-30T15:23:56Z</dc:date>
    </item>
    <item>
      <title>Re: Problems on android</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/problems-on-android/m-p/561552#M52427</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;If you have a support contract with Esri you can file a bug report at &lt;A href="http://support.esri.com"&gt;http://support.esri.com&lt;/A&gt;.&amp;nbsp; As far as I know that is the only way to file a bug report, but the JS API devs do read this forum.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Ok, thanks. I'll wait for a dev to come around then.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 May 2013 06:08:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/problems-on-android/m-p/561552#M52427</guid>
      <dc:creator>ThomasCoopman</dc:creator>
      <dc:date>2013-05-02T06:08:01Z</dc:date>
    </item>
  </channel>
</rss>

