Map panning and zooming too slow.........

by Pratap » Mon, 04 Jan 2010 15:04:23 GMT


Sponsored Links
 I've developed a GPS app in which i record the user roots and show it
on the map.......but
Panning around on the map when reviewing my route is painfully slow,
it takes at least 4 or 5 seconds for the map to respond the finger
swipes......

I've overridden the onDraw()  method and drawing the lines to show the
routes......is there any better way to do this so that panning becomes
faster as in "MyTracks"...........

Thank you all.....
Pratap S.

--



Other Threads

1. java.lang.RuntimeException: Binary XML file line #26: You must supply a layout_height attribute.

I get the following error in logcat:

java.lang.RuntimeException: Binary XML file line #26: You must supply
a layout_height attribute.

Can you please tell me which xml file that I am missing? And it said
'binary xml', does it mean it is actually line 26 in my file?
or it is line 26 in the file after it compiles to be a binary xml file?

Thank you.


02-15 17:19:58.873: WARN/WindowManager(50): Exception when adding
starting window
02-15 17:19:58.873: WARN/WindowManager(50):
java.lang.RuntimeException: Binary XML file line #26: You must supply
a layout_height attribute.
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.content.res.TypedArray.getLayoutDimension(TypedArray.java:438)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.view.ViewGroup$LayoutParams.setBaseAttributes(ViewGroup.java:3236)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.view.ViewGroup$MarginLayoutParams.<init>(ViewGroup.java:3315)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.widget.LinearLayout$LayoutParams.<init>(LinearLayout.java:1262)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.widget.LinearLayout.generateLayoutParams(LinearLayout.java:1188)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.widget.LinearLayout.generateLayoutParams(LinearLayout.java:45)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.view.LayoutInflater.rInflate(LayoutInflater.java:619)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.view.LayoutInflater.inflate(LayoutInflater.java:407)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.view.LayoutInflater.inflate(LayoutInflater.java:320)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.view.LayoutInflater.inflate(LayoutInflater.java:276)
02-15 17:19:58.873: WARN/WindowManager(50):     at
com.android.internal.policy.impl.PhoneWindow.generateLayout(PhoneWindow.java:1989)
02-15 17:19:58.873: WARN/WindowManager(50):     at
com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:2043)
02-15 17:19:58.873: WARN/WindowManager(50):     at
com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1291)
02-15 17:19:58.873: WARN/WindowManager(50):     at
com.android.internal.policy.impl.PhoneWindowManager.addStartingWindow(PhoneWindowManager.java:541)
02-15 17:19:58.873: WARN/WindowManager(50):     at
com.android.server.WindowManagerService$H.handleMessage(WindowManagerService.java:5905)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.os.Handler.dispatchMessage(Handler.java:88)
02-15 17:19:58.873: WARN/WindowManager(50):     at
android.os.Looper.loop(Looper.java:123)
02-15 17:19:58.873: WARN/WindowManager(50):     at
com.android.server.WindowManagerService$WMThread.run(WindowManagerService.java:372)

--~--~---------~--~----~------------~-------~--~----~

2. How to use Webview as a ListItem and have smooth scrolling?

Using WebViews inside a ListView is a bad idea. We tried :) The
biggest problem is that when you load data inside a WebView, it takes
some time to do the parsing/layout and it happens that it is too slow
in the case of scrolling a ListView.

As for the scrollbars, Cupcake has a solution for it. There is a new
attribute for ListView telling it to disable smooth scrollbars; that's
what you want when the items have (very) different heights.






-- 
Romain Guy
Android framework engineer
romain...@android.com

Note: please don't send private questions to me, as I don't have time
to provide private support.  All such questions should be posted on
public forums, where I and others can see and answer them

--~--~---------~--~----~------------~-------~--~----~

3. How to use Webview as a ListItem and have smooth scrolling?

4. java.lang.RuntimeException: Binary XML file line #26: You must supply a layout_height attribute.

5. Best way to parse [KX]ML in Android?

6. Changing default theme for OEMs and Android compatibility

7. MediaPlayer plays sound but screen is black