<?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: Samples not filling in display on orientationchange in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673731#M62800</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I tried it on my Android, but the sample doesn't even work on it.&amp;nbsp; But if you look at the code for that sample, it is not doing anything in the orientationChanged function:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; function orientationChanged() {&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the other samples, they have this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; function orientationChanged() {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if(map){&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; map.reposition();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; map.resize();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 12 Apr 2011 14:40:06 GMT</pubDate>
    <dc:creator>JustinGreco</dc:creator>
    <dc:date>2011-04-12T14:40:06Z</dc:date>
    <item>
      <title>Samples not filling in display on orientationchange</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673730#M62799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;So, I am looking at this sample:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/javascript/arcgis/demos/widget/widget_mobilegallery.html"&gt;http://help.arcgis.com/en/webapi/javascript/arcgis/demos/widget/widget_mobilegallery.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Select a map and in portrait, once the map loads, rotate the phone to landscape.&amp;nbsp; There is a big gap off to the right.&amp;nbsp; This also happens in&amp;nbsp; very simple map web app I have locally.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this a jQuery Mobile issue?&amp;nbsp; Why isn't the map filling in the gap when map.reposition() and map.resize() are called.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;(see attached photo)&lt;/SPAN&gt;&lt;BR /&gt;&lt;IMG src="http://www.goodrichs.net/photo.PNG" /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We've reproduced this behavior on an iPhone4 and iPhone 3GS&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Glenn&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Mar 2011 14:39:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673730#M62799</guid>
      <dc:creator>GlennGoodrich</dc:creator>
      <dc:date>2011-03-18T14:39:12Z</dc:date>
    </item>
    <item>
      <title>Re: Samples not filling in display on orientationchange</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673731#M62800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I tried it on my Android, but the sample doesn't even work on it.&amp;nbsp; But if you look at the code for that sample, it is not doing anything in the orientationChanged function:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; function orientationChanged() {&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the other samples, they have this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; function orientationChanged() {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if(map){&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; map.reposition();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; map.resize();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Apr 2011 14:40:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673731#M62800</guid>
      <dc:creator>JustinGreco</dc:creator>
      <dc:date>2011-04-12T14:40:06Z</dc:date>
    </item>
    <item>
      <title>Re: Samples not filling in display on orientationchange</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673732#M62801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I think this is an iOS bug.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://filamentgroup.com/examples/iosScaleBug/"&gt;http://filamentgroup.com/examples/iosScaleBug/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I played around with this trying to find a workaround but the scaling was too big, as the bug states, when the orientation changed.&amp;nbsp; I don't think this problem will be resolved until Apple addresses the bug and I haven't found a decent workaround for it.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Also, check out the following blog post from the jQuery Mobile team about Pinch-to-zoom: Now Restored.&amp;nbsp; They make reference to this bug in their post.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://jquerymobile.com/blog/2011/05/20/jquery-mobile-team-update-%E2%80%93-week-of-may-16th/"&gt;http://jquerymobile.com/blog/2011/05/20/jquery-mobile-team-update-%E2%80%93-week-of-may-16th/&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jun 2011 15:09:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673732#M62801</guid>
      <dc:creator>SteveClarke</dc:creator>
      <dc:date>2011-06-28T15:09:17Z</dc:date>
    </item>
    <item>
      <title>Re: Samples not filling in display on orientationchange</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673733#M62802</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Please note that I'm not an esri employee even though the esri logo is showing up beneath my name on the left of the forum posting.&amp;nbsp; I've requested the forum administrator to remove it so as not to cause confusion.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jun 2011 15:27:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673733#M62802</guid>
      <dc:creator>SteveClarke</dc:creator>
      <dc:date>2011-06-28T15:27:29Z</dc:date>
    </item>
    <item>
      <title>Re: Samples not filling in display on orientationchange</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673734#M62803</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;A user on the jQuery Mobile forum suggested the following:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;var changeViewport = function () {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (window.orientation == 90 || window.orientation == 270)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; $('meta[name="viewport"]').attr('content', 'height=device-width,width=device-height,initial-scale=1.0,maximum-scale=1.0');&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; $('meta[name="viewport"]').attr('content', 'height=device-height,width=device-width,initial-scale=1.0,maximum-scale=1.0');&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; window.addEventListener('orientationchange', changeViewport, true);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; try { changeViewport(); } catch (err) { } &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I tried this with moderate success, at least it's the best solution I've seen so far to this problem.&amp;nbsp; But it only seems to work if I execute a task first against the map.&amp;nbsp; For example, I have to execute a task in my app that will find a feature and zoom to it on the map.&amp;nbsp; Then when I rotate my iOS device to landscape the map will fill the entire screen but my toolbars at the top of the map are hidden.&amp;nbsp; I have to tap the iOS bar at the top of the screen (that shows the time and the wifi connection strength) and then I can see my toolbar at the top of the app.&amp;nbsp; Of course, the browser's url bar also appears, but you can tap and hold the toolbar and scroll up until the url bar disappears.&amp;nbsp; The good news is that the app didn't scale too large like in my previous attempts.&amp;nbsp; And now when I rotate back to portrait the app displays normally and the map fills the entire screen as expected.&amp;nbsp; So this code is at least a step in the right direction.&amp;nbsp; Hopefully this will give you something to go on for a workaround until Apple fixes the bug.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Jun 2011 14:24:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673734#M62803</guid>
      <dc:creator>SteveClarke</dc:creator>
      <dc:date>2011-06-29T14:24:52Z</dc:date>
    </item>
    <item>
      <title>Re: Samples not filling in display on orientationchange</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673735#M62804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Steve,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I just tried your code snippet in an app I am working on, and so far so good.&amp;nbsp; Tested it on my LG G2x (Android), and my co-workers iPhone and it works great!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for sharing!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Jan 2012 17:09:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/samples-not-filling-in-display-on/m-p/673735#M62804</guid>
      <dc:creator>AaronDrake</dc:creator>
      <dc:date>2012-01-20T17:09:00Z</dc:date>
    </item>
  </channel>
</rss>

