02-18 17:17:58.929: E/ACRA(6889): com.App.mobileapp fatal error : null
02-18 17:17:58.929: E/ACRA(6889): java.lang.StackOverflowError
02-18 17:17:58.929: E/ACRA(6889): at maps.c.n.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.c.n.b(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.c.n.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.a.ae.d(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.a.bq.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.y.al.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.y.ae.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.y.ae.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.y.ae.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.y.bu.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at maps.y.p.onCreateView(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at com.google.android.gms.maps.internal.IMapFragmentDelegate$Stub.onTransact(IMapFragmentDelegate.java:107)
02-18 17:17:58.929: E/ACRA(6889): at android.os.Binder.transact(Binder.java:279)
02-18 17:17:58.929: E/ACRA(6889): at com.google.android.gms.maps.internal.IMapFragmentDelegate$a$a.onCreateView(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at com.google.android.gms.maps.SupportMapFragment$a.onCreateView(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at com.google.android.gms.internal.d$4.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at com.google.android.gms.internal.d.a(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at com.google.android.gms.internal.d.onCreateView(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at com.google.android.gms.maps.SupportMapFragment.onCreateView(Unknown Source)
02-18 17:17:58.929: E/ACRA(6889): at com.App.mobileapp.maps.MapFragment.onCreateView(MapFragment.java:19)
02-18 17:17:58.929: E/ACRA(6889): at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:846)
02-18 17:17:58.929: E/ACRA(6889): at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1061)
02-18 17:17:58.929: E/ACRA(6889): at android.support.v4.app.FragmentManagerImpl.addFragment(FragmentManager.java:1160)
02-18 17:17:58.929: E/ACRA(6889): at android.support.v4.app.FragmentActivity.onCreateView(FragmentActivity.java:272)
02-18 17:17:58.929: E/ACRA(6889): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:563)
02-18 17:17:58.929: E/ACRA(6889): at android.view.LayoutInflater.rInflate(LayoutInflater.java:623)
02-18 17:17:58.929: E/ACRA(6889): at android.view.LayoutInflater.inflate(LayoutInflater.java:408)
02-18 17:17:58.929: E/ACRA(6889): at android.view.LayoutInflater.inflate(LayoutInflater.java:320)
02-18 17:17:58.929: E/ACRA(6889): at android.view.LayoutInflater.inflate(LayoutInflater.java:276)
02-18 17:17:58.929: E/ACRA(6889): at com.actionbarsherlock.internal.ActionBarSherlockCompat.setContentView(ActionBarSherlockCompat.java:853)
02-18 17:17:58.929: E/ACRA(6889): at com.actionbarsherlock.app.SherlockFragmentActivity.setContentView(SherlockFragmentActivity.java:262)
02-18 17:17:58.929: E/ACRA(6889): at com.App.mobileapp.maps.SearchViewOnMapActivity.onCreate(mMapActivity.java:67)
02-18 17:17:58.929: E/ACRA(6889): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
02-18 17:17:58.929: E/ACRA(6889): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1615)
02-18 17:17:58.929: E/ACRA(6889): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1667)
02-18 17:17:58.929: E/ACRA(6889): at android.app.ActivityThread.access$1500(ActivityThread.java:117)
02-18 17:17:58.929: E/ACRA(6889): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:935)
02-18 17:17:58.929: E/ACRA(6889): at android.os.Handler.dispatchMessage(Handler.java:99)
02-18 17:17:58.929: E/ACRA(6889): at android.os.Looper.loop(Looper.java:130)
02-18 17:17:58.929: E/ACRA(6889): at android.app.ActivityThread.main(ActivityThread.java:3687)
02-18 17:17:58.929: E/ACRA(6889): at java.lang.reflect.Method.invokeNative(Native Method)
02-18 17:17:58.929: E/ACRA(6889): at java.lang.reflect.Method.invoke(Method.java:507)
02-18 17:17:58.929: E/ACRA(6889): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867)
02-18 17:17:58.929: E/ACRA(6889): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:625)
02-18 17:17:58.929: E/ACRA(6889): at dalvik.system.NativeStart.main(Native Method)
这是堆栈跟踪
在setContentView(R.layout.map);
的mMapActivity
并且MapFragment.java:19
是
View root = super.onCreateView(inflater, container, savedInstanceState);
完成 MapFragment.java
public class MapFragment extends SherlockMapFragment {
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
View root = super.onCreateView(inflater, container, savedInstanceState);
return root;
}
}
地图.xml
<?xml version="1.0" encoding="utf-8"?>
<fragment
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/map_searchViewOnMap"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@id/loadButton_searchViewOnMap"
class="com.App.mobileapp.maps.MapFragment" />