ViewAnimator causes NullPointerException - android

Hey i'm trying to use ViewAnimator and i probably am missing something basic.
This is what i have :
va = new ViewAnimator(this);
va.setInAnimation(inFromLeftAnimation());
va.setOutAnimation(outToRightAnimation());
RelativeLayout stage = (RelativeLayout)findViewById(R.layout.american_stage);
va.addView(stage,0);
setContentView(va);
Where inFromLeftAnimation and outToRightAnimation just handles animations and works perfectly.
And ofcourse that the file really exists...
I Get this log :
07-13 15:45:14.515: E/AndroidRuntime(564): java.lang.RuntimeException: Unable to start activity ComponentInfo{shibby.webhunt/shibby.webhunt.ArcadeModeActivity}: java.lang.NullPointerException
07-13 15:45:14.515: E/AndroidRuntime(564): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2663)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.app.ActivityThread.access$2300(ActivityThread.java:125)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.os.Handler.dispatchMessage(Handler.java:99)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.os.Looper.loop(Looper.java:123)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.app.ActivityThread.main(ActivityThread.java:4627)
07-13 15:45:14.515: E/AndroidRuntime(564): at java.lang.reflect.Method.invokeNative(Native Method)
07-13 15:45:14.515: E/AndroidRuntime(564): at java.lang.reflect.Method.invoke(Method.java:521)
07-13 15:45:14.515: E/AndroidRuntime(564): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
07-13 15:45:14.515: E/AndroidRuntime(564): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
07-13 15:45:14.515: E/AndroidRuntime(564): at dalvik.system.NativeStart.main(Native Method)
07-13 15:45:14.515: E/AndroidRuntime(564): Caused by: java.lang.NullPointerException
07-13 15:45:14.515: E/AndroidRuntime(564): at android.view.ViewGroup.addView(ViewGroup.java:1815)
07-13 15:45:14.515: E/AndroidRuntime(564): at shibby.webhunt.ArcadeModeActivity.onCreate(ArcadeModeActivity.java:25)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
07-13 15:45:14.515: E/AndroidRuntime(564): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
And i have no idea why.
Is it impossible to use XML files as views? do i have to build the views myself?

07-13 15:45:14.515: E/AndroidRuntime(564): Caused by: java.lang.NullPointerException
07-13 15:45:14.515: E/AndroidRuntime(564): at android.view.ViewGroup.addView(ViewGroup.java:1815)
It looks like you are trying to add a View (RelativeLayout stage) that is null, I don't believe you can load a layout with findViewById():
findViewById(R.layout.american_stage);
If you are trying to open a non-visible layout in american_stage.xml, use a LayoutInflater:
LayoutInflater layoutInflater = (LayoutInflater) getSystemService(LAYOUT_INFLATER_SERVICE);
stage = layoutInflater.inflate(R.layout.american_stage, null);
Or if you are trying to load an already visible RelativeLayout:
1) Give the RelativeLayout the id american_stage
<RelativeLayout
android:id="#+id/american_stage"
...
2) And use:
findViewById(R.id.american_stage);

Related

Titanium Android application continuosly crashes

I have developed an android application using Titanium sdk 3.5.1.The modules used in application are:
LocationServiceModele and PushSubscription module.
The problem is that ,in some devices the application continously crashes and restart the application.The error shows in DDms is:
application log
07-13 17:49:54.598: E/TiApplication(11402): at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1194)
07-13 17:49:54.598: E/TiApplication(11402): at android.app.Activity.performStart(Activity.java:5258)
07-13 17:49:54.598: E/TiApplication(11402): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2171)
07-13 17:49:54.598: E/TiApplication(11402): ... 11 more
07-13 17:49:54.639: E/AndroidRuntime(11402): FATAL EXCEPTION: main
07-13 17:49:54.639: E/AndroidRuntime(11402): Process: com.qatartips, PID: 11402
07-13 17:49:54.639: E/AndroidRuntime(11402): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.qatartips/org.appcelerator.titanium.TiActivity}: java.lang.NullPointerException
07-13 17:49:54.639: E/AndroidRuntime(11402): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2198)
07-13 17:49:54.639: E/AndroidRuntime(11402): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2257)
07-13 17:49:54.639: E/AndroidRuntime(11402): at android.app.ActivityThread.access$800(ActivityThread.java:139)
07-13 17:49:54.639: E/AndroidRuntime(11402): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1210)
07-13 17:49:54.639: E/AndroidRuntime(11402): at android.os.Handler.dispatchMessage(Handler.java:102)
07-13 17:49:54.639: E/AndroidRuntime(11402): at android.os.Looper.loop(Looper.java:136)
07-13 17:49:54.639: E/AndroidRuntime(11402): at android.app.ActivityThread.main(ActivityThread.java:5086)
07-13 17:49:54.639: E/AndroidRuntime(11402): at java.lang.reflect.Method.invokeNative(Native Method)
07-13 17:49:54.639: E/AndroidRuntime(11402): at java.lang.reflect.Method.invoke(Method.java:515)
07-13 17:49:54.639: E/AndroidRuntime(11402): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785)
07-13 17:49:54.639: E/AndroidRuntime(11402): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601)
07-13 17:49:54.639: E/AndroidRuntime(11402): at dalvik.system.NativeStart.main(Native Method)
07-13 17:49:54.639: E/AndroidRuntime(11402): Caused by: java.lang.NullPointerException
07-13 17:49:54.639: E/AndroidRuntime(11402): at com.android.internal.policy.impl.PhoneWindow.updateProgressBars(PhoneWindow.java:1367)
07-13 17:49:54.639: E/AndroidRuntime(11402): at com.android.internal.policy.impl.PhoneWindow.onIntChanged(PhoneWindow.java:1322)
07-13 17:49:54.639: E/AndroidRuntime(11402): at com.android.internal.policy.impl.PhoneWindow.updateInt(PhoneWindow.java:3341)
07-13 17:49:54.639: E/AndroidRuntime(11402): at com.android.internal.policy.impl.PhoneWindow.setFeatureInt(PhoneWindow.java:1267)

NoClassDefFound Exception when trying to use custom external widget

I am trying to implement Caldroid (https://github.com/roomorama/Caldroid) in my own project. I looked at the sample app given and it had the app separate from the project that defined the widget. I have done the same thing. The code compiles, but when I try to run the app I am getting a NoClassDefFound exception when trying to call the widget. Here is the code for setting up the calendar
private void calendarSetup(Bundle savedInstanceState) {
caldroidFragment = new CaldroidFragment();
if (savedInstanceState != null) {
caldroidFragment.restoreStatesFromKey(savedInstanceState,
"CALDROID_SAVED_STATE");
}
// If activity is created from fresh
else {
Bundle args = new Bundle();
Calendar cal = Calendar.getInstance();
args.putInt(CaldroidFragment.MONTH, cal.get(Calendar.MONTH) + 1);
args.putInt(CaldroidFragment.YEAR, cal.get(Calendar.YEAR));
args.putBoolean(CaldroidFragment.ENABLE_SWIPE, true);
args.putBoolean(CaldroidFragment.SIX_WEEKS_IN_CALENDAR, true);
caldroidFragment.setArguments(args);
}
// Attach to the activity
FragmentTransaction t = getActivity().getSupportFragmentManager()
.beginTransaction();
t.replace(R.id.calendar, caldroidFragment);
t.commit();
}
Here is the logcat
07-13 17:24:30.254: E/AndroidRuntime(2563): FATAL EXCEPTION: main
07-13 17:24:30.254: E/AndroidRuntime(2563): Process: com.example.app, PID: 2563
07-13 17:24:30.254: E/AndroidRuntime(2563): java.lang.NoClassDefFoundError: com.roomorama.caldroid.CaldroidFragment
07-13 17:24:30.254: E/AndroidRuntime(2563): at com.example.app.fragments.MyActivity.calendarSetup(app.java:123)
07-13 17:24:30.254: E/AndroidRuntime(2563): at com.example.app.fragments.MyActivity.onCreateView(app.java:68)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.support.v4.app.Fragment.performCreateView(Fragment.java:1500)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:927)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1104)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:682)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1467)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.support.v4.app.FragmentActivity.onStart(FragmentActivity.java:570)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1171)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.app.Activity.performStart(Activity.java:5241)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2168)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.app.ActivityThread.access$800(ActivityThread.java:135)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.os.Handler.dispatchMessage(Handler.java:102)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.os.Looper.loop(Looper.java:136)
07-13 17:24:30.254: E/AndroidRuntime(2563): at android.app.ActivityThread.main(ActivityThread.java:5017)
07-13 17:24:30.254: E/AndroidRuntime(2563): at java.lang.reflect.Method.invokeNative(Native Method)
07-13 17:24:30.254: E/AndroidRuntime(2563): at java.lang.reflect.Method.invoke(Method.java:515)
07-13 17:24:30.254: E/AndroidRuntime(2563): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
07-13 17:24:30.254: E/AndroidRuntime(2563): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
07-13 17:24:30.254: E/AndroidRuntime(2563): at dalvik.system.NativeStart.main(Native Method)
The line at which the error is occurring is when I try to instantiate a CaldroidFragment.
I have added the external project to the build path of this current one as has been mentioned in other SO answers. However this doesn't seem to work.
Thanks.
I have added the external project to the build path of this current one as has been mentioned in other SO answers.
None of those answers are right. If you are manually manipulating the build path in Eclipse, you're probably doing it wrong.
For a third-party library that is a JAR, copy it into libs/, and you are done. Do not alter the build path manually.
For a third-party library that is an Android library project — as Caldroid is — you need to import the library into your Eclipse workspace, then attach the library to your app project via Project > Properties > Android. This is covered in greater detail in the documentation. Do not alter the build path manually.

Run time exception: unable to instantiate activity component [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions concerning problems with code you've written must describe the specific problem — and include valid code to reproduce it — in the question itself. See SSCCE.org for guidance.
Closed 9 years ago.
Improve this question
Trying to Integrate facebook sdk to android app but my app is not starting. There are the logs. How can I fix this runtime exception?
#Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
ImageView pic = (ImageView) findViewById(R.id.imageView1);
Button btn = (Button) findViewById(R.id.button1);
btn.setOnClickListener(this);
}
08-15 11:48:21.712: E/AndroidRuntime(564): FATAL EXCEPTION: main
08-15 11:48:21.712: E/AndroidRuntime(564): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.sri.z4globalsoft/com.sri.z4globalsoft.MainActivity}: java.lang.NullPointerException
08-15 11:48:21.712: E/AndroidRuntime(564): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1879)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1980)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.app.ActivityThread.access$600(ActivityThread.java:122)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1146)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.os.Handler.dispatchMessage(Handler.java:99)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.os.Looper.loop(Looper.java:137)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.app.ActivityThread.main(ActivityThread.java:4340)
08-15 11:48:21.712: E/AndroidRuntime(564): at java.lang.reflect.Method.invokeNative(Native Method)
08-15 11:48:21.712: E/AndroidRuntime(564): at java.lang.reflect.Method.invoke(Method.java:511)
08-15 11:48:21.712: E/AndroidRuntime(564): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
08-15 11:48:21.712: E/AndroidRuntime(564): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
08-15 11:48:21.712: E/AndroidRuntime(564): at dalvik.system.NativeStart.main(Native Method)
08-15 11:48:21.712: E/AndroidRuntime(564): Caused by: java.lang.NullPointerException
08-15 11:48:21.712: E/AndroidRuntime(564): at android.content.ContextWrapper.getResources(ContextWrapper.java:81)
08-15 11:48:21.712: E/AndroidRuntime(564): at com.sri.z4globalsoft.MainActivity.<init>(MainActivity.java:23)
08-15 11:48:21.712: E/AndroidRuntime(564): at java.lang.Class.newInstanceImpl(Native Method)
08-15 11:48:21.712: E/AndroidRuntime(564): at java.lang.Class.newInstance(Class.java:1319)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.app.Instrumentation.newActivity(Instrumentation.java:1023)
08-15 11:48:21.712: E/AndroidRuntime(564): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1870)
08-15 11:48:21.712: E/AndroidRuntime(564): ... 11 more
Tried by changing the code ap per your answers given below then also having problem
08-15 12:25:00.800: E/AndroidRuntime(712): FATAL EXCEPTION: main
08-15 12:25:00.800: E/AndroidRuntime(712): java.lang.NoClassDefFoundError: com.facebook.android.Facebook
08-15 12:25:00.800: E/AndroidRuntime(712): at com.sri.z4globalsoft.MainActivity.<init>(MainActivity.java:25)
08-15 12:25:00.800: E/AndroidRuntime(712): at java.lang.Class.newInstanceImpl(Native Method)
08-15 12:25:00.800: E/AndroidRuntime(712): at java.lang.Class.newInstance(Class.java:1319)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.app.Instrumentation.newActivity(Instrumentation.java:1023)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1870)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1980)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.app.ActivityThread.access$600(ActivityThread.java:122)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1146)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.os.Handler.dispatchMessage(Handler.java:99)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.os.Looper.loop(Looper.java:137)
08-15 12:25:00.800: E/AndroidRuntime(712): at android.app.ActivityThread.main(ActivityThread.java:4340)
08-15 12:25:00.800: E/AndroidRuntime(712): at java.lang.reflect.Method.invokeNative(Native Method)
08-15 12:25:00.800: E/AndroidRuntime(712): at java.lang.reflect.Method.invoke(Method.java:511)
08-15 12:25:00.800: E/AndroidRuntime(712): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
08-15 12:25:00.800: E/AndroidRuntime(712): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
08-15 12:25:00.800: E/AndroidRuntime(712): at dalvik.system.NativeStart.main(Native Method)
It sound like you might be trying to use getResources() before they are technically ready.
If you have this:
String APP_ID = getResources().getString(R.string.APP_ID);
#Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
...
}
Do this instead:
String APP_ID;
#Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
APP_ID = getResources().getString(R.string.APP_ID);
...
}
08-15 11:48:21.712: E/AndroidRuntime(564): Caused by: java.lang.NullPointerException
08-15 11:48:21.712: E/AndroidRuntime(564): at android.content.ContextWrapper.getResources(ContextWrapper.java:81)
08-15 11:48:21.712: E/AndroidRuntime(564): at com.sri.z4globalsoft.MainActivity.<init>(MainActivity.java:23)
You're trying to initialize a member variable where the initialization is using this as Context. In this case it's the getResources() call. You can only use the Activity as a Context in onCreate() or later in the activity lifecycle.
Specifically (from question comments), change this:
String APP_ID = getResources().getString(R.string.APP_ID);
to something like:
String APP_ID;
#Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
APP_ID = getResources().getString(R.string.APP_ID);
//...

restartLoader in the onStart method throw Exception

I am using the android compatibility package to use Loaders . when i init a loader or restart it in the onCreate method , it just wroks find but when i restart or init it in the onStart it throw an error , what I want know why " some times " when I initLoader in the onCreate of the activity and click some button that move me quickly to another activity before the loader bind the data to the UI ,and return back to the activity that previously init the Loader the loader doesnot load the data "nothing appears on the UI ?!!!! so i thought that move the initLoader to onStart but it throw an error
07-13 03:19:15.140: E/AndroidRuntime(23179): java.lang.RuntimeException: Unable to resume activity {biz.dot.khtmeh/biz.dot.khtmeh.ui.HomeScreen}: java.lang.IllegalStateException: There is already a listener registered
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:2444)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:2472)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1173)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.os.Handler.dispatchMessage(Handler.java:99)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.os.Looper.loop(Looper.java:137)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.app.ActivityThread.main(ActivityThread.java:4424)
07-13 03:19:15.140: E/AndroidRuntime(23179): at java.lang.reflect.Method.invokeNative(Native Method)
07-13 03:19:15.140: E/AndroidRuntime(23179): at java.lang.reflect.Method.invoke(Method.java:511)
07-13 03:19:15.140: E/AndroidRuntime(23179): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
07-13 03:19:15.140: E/AndroidRuntime(23179): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
07-13 03:19:15.140: E/AndroidRuntime(23179): at dalvik.system.NativeStart.main(Native Method)
07-13 03:19:15.140: E/AndroidRuntime(23179): Caused by: java.lang.IllegalStateException: There is already a listener registered
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.support.v4.content.Loader.registerListener(Loader.java:130)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.support.v4.app.LoaderManagerImpl$LoaderInfo.start(LoaderManager.java:259)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.support.v4.app.LoaderManagerImpl.installLoader(LoaderManager.java:509)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.support.v4.app.LoaderManagerImpl.createAndInstallLoader(LoaderManager.java:496)
07-13 03:19:15.140: E/AndroidRuntime(23179): at android.support.v4.app.LoaderManagerImpl.restartLoader(LoaderManager.java:642)
It is likely you are re-using a loader more than once. Each time onCreateLoader(..) is called, you should be returning a new instance of a Loader<T>.

ListView Force Close

I am writing a Class that gets the File's in a folder, and displays the contents in a list view. the application force closes when i run this activity... I Debugged for a while, and searched through logcat, and I cannot find the problem...
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
File root = new File(Environment.getExternalStorageDirectory(), "Notes");
if(!root.exists()){
root.mkdirs();
}
setListAdapter(new ArrayAdapter<String>(this, R.layout.folders, buildDirArray(root)));
ListView lv = getListView();
lv.setTextFilterEnabled(true);
lv.setOnItemClickListener(new OnItemClickListener() {
public void onItemClick(AdapterView<?> parent, View view,
int position, long id) {
// When clicked, show a toast with the TextView text
Toast.makeText(getApplicationContext(), ((TextView) view).getText(),
Toast.LENGTH_SHORT).show();
}
});
}
public String[] buildDirArray(File dir){
int temp = dir.list().length;
String[] tm = dir.list();
String[] tmp = new String[temp];
for(int i=1;i==dir.list().length;i++){
tmp[i]=tm[i];
}
return tmp;
}
ANY help would be greatly appreciated...
Logcat Data:
07-13 20:41:21.205: ERROR/Zygote(32): setreuid() failed. errno: 2
07-13 20:41:29.045: ERROR/Zygote(32): setreuid() failed. errno: 17
07-13 20:41:30.345: ERROR/BatteryService(58): usbOnlinePath not found
07-13 20:41:30.345: ERROR/BatteryService(58): batteryVoltagePath not found
07-13 20:41:30.345: ERROR/BatteryService(58): batteryTemperaturePath not found
07-13 20:41:30.364: ERROR/SurfaceFlinger(58): Couldn't open /sys/power/wait_for_fb_sleep or /sys/power/wait_for_fb_wake
07-13 20:41:36.015: ERROR/EventHub(58): could not get driver version for /dev/input/mouse0, Not a typewriter
07-13 20:41:36.015: ERROR/EventHub(58): could not get driver version for /dev/input/mice, Not a typewriter
07-13 20:41:36.295: ERROR/System(58): Failure starting core service
07-13 20:41:36.295: ERROR/System(58): java.lang.SecurityException
07-13 20:41:36.295: ERROR/System(58): at android.os.BinderProxy.transact(Native Method)
07-13 20:41:36.295: ERROR/System(58): at android.os.ServiceManagerProxy.addService(ServiceManagerNative.java:146)
07-13 20:41:36.295: ERROR/System(58): at android.os.ServiceManager.addService(ServiceManager.java:72)
07-13 20:41:36.295: ERROR/System(58): at com.android.server.ServerThread.run(SystemServer.java:184)
07-13 20:41:37.315: ERROR/SoundPool(58): error loading /system/media/audio/ui/Effect_Tick.ogg
07-13 20:41:37.325: ERROR/SoundPool(58): error loading /system/media/audio/ui/KeypressStandard.ogg
07-13 20:41:37.325: ERROR/SoundPool(58): error loading /system/media/audio/ui/KeypressSpacebar.ogg
07-13 20:41:37.346: ERROR/SoundPool(58): error loading /system/media/audio/ui/KeypressDelete.ogg
07-13 20:41:37.356: ERROR/SoundPool(58): error loading /system/media/audio/ui/KeypressReturn.ogg
07-13 20:41:40.414: ERROR/ThrottleService(58): Could not open GPS configuration file /etc/gps.conf
07-13 20:41:42.795: ERROR/logwrapper(147): executing /system/bin/tc failed: No such file or directory
07-13 20:41:42.945: ERROR/logwrapper(148): executing /system/bin/tc failed: No such file or directory
07-13 20:41:43.065: ERROR/logwrapper(149): executing /system/bin/tc failed: No such file or directory
07-13 20:41:54.824: ERROR/HierarchicalStateMachine(58): TetherMaster - unhandledMessage: msg.what=3
07-13 20:43:11.984: ERROR/AndEngine(282): You have to add
07-13 20:43:11.984: ERROR/AndEngine(282): <uses-permission android:name="android.permission.WAKE_LOCK"/>
07-13 20:43:11.984: ERROR/AndEngine(282): to your AndroidManifest.xml !
07-13 20:43:11.984: ERROR/AndEngine(282): java.lang.SecurityException: Neither user 10033 nor current process has android.permission.WAKE_LOCK.
07-13 20:43:11.984: ERROR/AndEngine(282): at android.os.Parcel.readException(Parcel.java:1247)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.os.Parcel.readException(Parcel.java:1235)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.os.IPowerManager$Stub$Proxy.acquireWakeLock(IPowerManager.java:236)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.os.PowerManager$WakeLock.acquire(PowerManager.java:250)
07-13 20:43:11.984: ERROR/AndEngine(282): at org.anddev.andengine.ui.activity.BaseGameActivity.acquireWakeLock(BaseGameActivity.java:202)
07-13 20:43:11.984: ERROR/AndEngine(282): at org.anddev.andengine.ui.activity.BaseGameActivity.doResume(BaseGameActivity.java:165)
07-13 20:43:11.984: ERROR/AndEngine(282): at org.anddev.andengine.ui.activity.BaseGameActivity.onWindowFocusChanged(BaseGameActivity.java:82)
07-13 20:43:11.984: ERROR/AndEngine(282): at com.android.internal.policy.impl.PhoneWindow$DecorView.onWindowFocusChanged(PhoneWindow.java:1981)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.view.View.dispatchWindowFocusChanged(View.java:3788)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:658)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.view.ViewRoot.handleMessage(ViewRoot.java:1921)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.os.Handler.dispatchMessage(Handler.java:99)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.os.Looper.loop(Looper.java:123)
07-13 20:43:11.984: ERROR/AndEngine(282): at android.app.ActivityThread.main(ActivityThread.java:4627)
07-13 20:43:11.984: ERROR/AndEngine(282): at java.lang.reflect.Method.invokeNative(Native Method)
07-13 20:43:11.984: ERROR/AndEngine(282): at java.lang.reflect.Method.invoke(Method.java:521)
07-13 20:43:11.984: ERROR/AndEngine(282): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
07-13 20:43:11.984: ERROR/AndEngine(282): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
07-13 20:43:11.984: ERROR/AndEngine(282): at dalvik.system.NativeStart.main(Native Method)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): FATAL EXCEPTION: main
07-13 20:43:20.614: ERROR/AndroidRuntime(282): android.content.ActivityNotFoundException: Unable to find explicit activity class {com.momentum.xpad/com.momentum.xpad.folders}; have you declared this activity in your AndroidManifest.xml?
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1404)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.app.Instrumentation.execStartActivity(Instrumentation.java:1378)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.app.Activity.startActivityForResult(Activity.java:2817)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.app.Activity.startActivity(Activity.java:2923)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.momentum.xpad.main.onOptionsItemSelected(main.java:69)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.app.Activity.onMenuItemSelected(Activity.java:2195)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.android.internal.policy.impl.PhoneWindow.onMenuItemSelected(PhoneWindow.java:730)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.android.internal.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:143)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.android.internal.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:855)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.android.internal.view.menu.IconMenuView.invokeItem(IconMenuView.java:532)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.android.internal.view.menu.IconMenuItemView.performClick(IconMenuItemView.java:122)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.view.View$PerformClick.run(View.java:8816)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.os.Handler.handleCallback(Handler.java:587)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.os.Handler.dispatchMessage(Handler.java:92)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.os.Looper.loop(Looper.java:123)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at android.app.ActivityThread.main(ActivityThread.java:4627)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at java.lang.reflect.Method.invokeNative(Native Method)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at java.lang.reflect.Method.invoke(Method.java:521)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
07-13 20:43:20.614: ERROR/AndroidRuntime(282): at dalvik.system.NativeStart.main(Native Method)
The log says that:
You have to add <uses-permission android:name="android.permission.WAKE_LOCK"/> to your AndroidManifest.xml !
Oh some lines further down there is an other error in the log:
android.content.ActivityNotFoundException: Unable to find explicit activity class {com.momentum.xpad/com.momentum.xpad.folders}; have you declared this activity in your AndroidManifest.xml?
android.content.ActivityNotFoundException: Unable to find explicit activity class {com.momentum.xpad/com.momentum.xpad.folders}; have you declared this activity in your AndroidManifest.xml?
Have you declared it in your Manifest?

Categories

Resources