1. Check out our app, Forums for Android! Download and leave feedback here!

Touchscreen forces close after second instance.

Discussion in 'Application Development' started by barley06, Oct 17, 2010.

  1. barley06

    barley06 New Member
    Thread Starter

    Oct 17, 2010
    Open Source Developer
    Eccles, Manchester
    Hi All,
    I hope someone can help me. I am a newbie to Android but experienced in other areas. I have been developing a game for some time now. The game uses the touchscreen to select blocks. Everything works fine at first. I then select back,l save the state of the score, the level and the timer, which is quite important to the game. On unPause, and resume, these integers and doubles are restored correctly. The problem I am facing is that when I touch the screen again, this causes a "Force Close". Do I need to save the state of the environment aswell e.g. the touchscreen or view. I am struggling to work out from logcat what is going wrong. I have included the following debug from logcat. I would appreciate any help.

    Karl :)

    W/WindowManager( 65): Key dispatching timed out sending to com.blastem/com.blastem.Blastem
    W/WindowManager( 65): Previous dispatch state: {{KeyEvent{action=1 code=82 repeat=0 meta=0 scancode=229 mFlags=8} to Window{43ef2108 Keyguard paused=false} @ 1287329205888 lw=Window{43ef2108 Keyguard paused=false} lb=android.view.ViewRoot$W@43f508c0 fin=false gfw=true ed=true tts=0 wf=false fp=false mcf=Window{43ef2108 Keyguard paused=false}}}
    W/WindowManager( 65): Current dispatch state: {{null to Window{4401c918 com.blastem/com.blastem.Blastem paused=false} @ 1287329318945 lw=Window{4401c918 com.blastem/com.blastem.Blastem paused=false} lb=android.os.BinderProxy@44015918 fin=false gfw=true ed=true tts=0 wf=false fp=false mcf=Window{4401c918 com.blastem/com.blastem.Blastem paused=false}}}
    I/Process ( 65): Sending signal. PID: 277 SIG: 3


  2. cp1

    cp1 Well-Known Member

    Apr 30, 2010
    Does it include the line number and procedure that is causing the error? It looks like the "null to Window" part is the problem -- are all references to your views properly set?

Share This Page