Discussion Forums  >  Uncategorized

Replies: 6    Views: 285

R2-D2
Apple Fan
Profile
Posts: 95
Reg: Jan 20, 2011
East Coast USA
950
02/16/11 04:01 PM (15 years ago)

Location Map v1.5 oddities

First off, the new v1.5 is still great, even after the few days of new car smell fades... I'm still loving it. Thanks for reactivating custom text/html pages, too. I'm using Location Maps and everything mostly works, but I've found a quirk. The map appears differently when it is used as a Home Screen Tab than it does if it's linked from a menu elsewhere in the app. When linked from a menu, the map page starts off with an entirely zoomed out view of the earth (flattened). It drops pins and zooms in so that the end result is properly zoomed in as far as necessary while still showing all pins on the map within the user's view. However, when used as a tab in the Tabbed Layout, the result is different. There is no animated zoom, it simply shows the already zoomed map. I can live without the animated zoom, in fact I'd prefer it didn't do that. The real problem lies here: the zoomed view is zoomed too far in, and cuts out of the view some of my locations (and in my case, the most important one!). It would be fine if I could utilize the Advanced Map Property Single Location Zoom Default Zoom (1-28) however this setting has no effect, presumably because this is a multi-location map.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
02/16/11 05:04 PM (15 years ago)
Hmm... this is interesting. It sound like you totally understand the concepts about the Zoom range with a single location, yes, has zero affect on maps with more than one pin. I have not heard about the behavior you describe but I do totally understand what you're saying. I'll get a look at it and see what I can come up with. My gut tells me that it's an issue with the way the app initializes. When it first launches, it needs to 'build' the home-screen for each tab, it does this before anything is visible. In the map-builder process, the map needs to adjust all kinds of sizes and such to be 'full screen' I wonder if the tab building process and the map building process are colliding somehow? I say this because both fo these processes are happening literally within milliseconds of each other and the map may need to understand a bit more about the layout than most other screens before it renders itself. Complicated. I'll look into it - great observation.
 
R2-D2
Apple Fan
Profile
Posts: 95
Reg: Jan 20, 2011
East Coast USA
950
like
02/16/11 06:50 PM (15 years ago)
It may be that it thinks the location is actually, onscreen, but in fact it's hidden by the Title/Nav bar up top. I realized this by turning the Nav bar to transparent and I could see it hidden back there. Still, the default zoom is different when in the Tab rather than a regular menu link. By adding another location further off screen, I was able to get the Map in the Tab to zoom further out. This is at least a temporary workaround for me, as it gets the map to show what I want to show, but I'd rather not have this extraneous pinpoint on the map in order to do this. Also, on the same subject, the zoom is way off on the Tab-place map when viewed in landscape mode. Likely because of the map-builder process at launch that you mentioned above, building the map tab out based upon a portrait orientation to start with.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
02/16/11 09:15 PM (15 years ago)
This is good info. I've already tested a few workarounds, some with moderate success, some not. Hoping to have a solution by morning? that will accomodate the tabs issue and the landscape issue. Again.....good feedback, thanks.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
02/17/11 11:48 PM (15 years ago)
OK, I think this will work... here's what I adjusted... a) BT_screen_map does not run it's layout-screen routine until it's 'about to appear' It was programmed to build-itself when it was initialized. This meant that it was doing a bunch of heavy lifting so it was already pre-built before you ever tapped the tab is was on. Now, it does this 'hard work' literally the moment you touch the tab (intead of before you tapped it). This seems to fix the layout - with or without tabs, it looks the same in my tests. b) BT_screen_map re-runs it's layout routine milliseconds after the device has rotated. The same method above re-runs each time it's rotated. This seems to have solved the map locations not showing after a rotation. Not sure what app of yours has locations so I didn't test the exact locations you have. I can if you provide them. Or, you can re-download the source and test yourself ;-) Note: Tonights work is the v1.5 Change Log so folks can see if they need to re-download anything. Of course they won't 'have to', just in case they want to. There is no easy way to know when the download server was updated - duh. Lemme know on the maps.
 
R2-D2
Apple Fan
Profile
Posts: 95
Reg: Jan 20, 2011
East Coast USA
950
like
02/18/11 09:41 AM (15 years ago)
That's great, I will re-download and check it out.
 
R2-D2
Apple Fan
Profile
Posts: 95
Reg: Jan 20, 2011
East Coast USA
950
like
02/19/11 05:25 PM (15 years ago)
David, I re-downloaded and compiled. The changes you made to the Location Map work as expected. It zooms to the appropriate level and re-zooms upon device rotation properly. Thanks!
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.