1

App is to create a mark on the google map. It creates a mark in the right place with the APIs up to 13.

GeoPoint longpressLocation = getProjection().fromPixels((int)event.getX(),
(int)event.getY());

But in 14+ it increases event.getY by roughly 40 pixels. It's also mentioned in manifest to hide the title bar:

<activity android:name=".Travelalarm" android:label="@string/app_name"  android:theme="@android:style/Theme.NoTitleBar">

Is there any good-looking decision except for simply decreasing it by that number of pixels with Build.VERSION.SDK_INT > 13?

riwnodennyk
  • 8,140
  • 4
  • 35
  • 37

1 Answers1

0

i have about 58 pixels with sdk 13 and about 110 pixel with sdk 14 only with event.getY();

moriero
  • 31
  • 1
  • 3
  • With the ActionBar I currently have to use `getProjection().fromPixels((int) event.getX(),(int) event.getY() - statusBarHeight - actionBarHeight);` – riwnodennyk Jun 16 '12 at 00:51
  • Where `statusBarHeight` and `actionBarHeight` can easily be attained by the recipe from http://stackoverflow.com/a/3410200/986216 (TitleBarHeight = actionBarHeight in this case) – riwnodennyk Jun 16 '12 at 01:06