• The above worked great for a single subview. I then tried removing the first subview and adding a second (as a way to switch between views).

    The second view exhibited the original problem, it didn't fill the screen.

    I found the solution here was to set the width and height of the second subview to match that of the root view. I assume additional views will also need this.

  • Thank you! I was previously unable to find remove_subview in the docs, but I went back again and see it there. Thanks for the help :)

  • You can throttle the API calls on your end by sleeping after each successful API call:

    import contacts, location, time for i, p in enumerate(contacts.get_all_people()): for addr_tag, addr in p.address: addr_tag = contacts.localized_label(addr_tag) print('{}, {}, {}'.format(i+1, p.full_name, addr_tag)) locs = location.geocode(addr) if locs: print(' {latitude},{longitude}'.format(**locs[0])) time.sleep(2) # comment out to go full speed else: print(' ERROR: unable to locate: {}'.format(addr))
  • I ended up creating a function to make this even cleaner.

    def _super(self): return super(self.__class__,self)

    With this it makes it much cleaner when you want to invoke the base class.

    class MyLayer (Layer): def draw(self,a=1.0): _super(self).draw(a)

    A lot nicer if you're coding on an iPhone with the small display :)

  • omz thanks for the reply, that's too bad but oh well :). Are there other ways (besides handle urls) to integrate with other apps ?

  • Thanks for the replies. ccc, did you find using urlencode worked reliably or did you have to combine that with the callback approach? I'm assuming with the callback approach you'd launch Google Maps and it would then in turn launch your script again so you'd have to save off the lat/lon and then bounce it back with that info. But if it works....

    I tried using the Apple maps app and that seems to work every time without even worrying about encoding the URL. My leaning would be to Google Maps but I guess the other advantage to using Apple maps is that you're guaranteed to have it installed on the device.

  • Check this...Python threading basics

  • .

  • d'oh! Well I guess I feel dumb now for spending all that time trying to correlate the touches using the prev position :) A unique ID is exactly what I was hoping for; I must have just missed it in the docs. Thanks, I think that'll work perfectly :)

Internal error.

Oops! Looks like something went wrong!