Problem fixed, although I have no idea why it was yielding this error.

On my code I was initializing a progress dialog as follows:

dialogWait = ProgressDialog.show(*this*, "",
getResources().getString(R.string.msg_please_wait), *true*, *true*);

       dialogWait.setOnCancelListener(*new* OnCancelListener() {



            @Override

            *public* *void* onCancel(DialogInterface dialog) {

                Log.d(FileSystemService.LOG_TAG, "onCancel()");

                remoteTask.cancel(*true*);

                setButtonsEnabled(*true*);



            }

        });

        dialogWait.hide();

I found out that the highlighted line was the problem after commenting all
the code, and then uncommenting line per line. I changed the initialization
of the dialog to a more standard one:

        dialogWait = new ProgressDialog(this);
        dialogWait.setTitle("");

dialogWait.setMessage(getResources().getString(R.string.msg_please_wait));
        dialogWait.setCancelable(true);
        dialogWait.setIndeterminate(true);

And everything was fine. Hope it helps. :o)


On Wed, Oct 5, 2011 at 2:43 PM, Alvaro Victor Cavalcanti <
alvarovic...@gmail.com> wrote:

> I'm facing the same problem here, but under different circumstances.
>
> I've also a standard and simple EditText, but my Avtivity does not have any
> special behaviour. At first, it's superclass implemented OnClickListener,
> which was overridden by the activity, and we removed that. Each callback
> function was created as an Anonymous inner-type, and things got working. At
> least for 30 min, then the bug showed up again.
>
> I tried your approach of using an AsyncTask, but as most of the
> initialization code is related to UI, it could not run in another thread.
> Even with the remaining code left on the task, the problem persisted.
>
> Have anybody else crossed this problem and got it solved?
>
> Oh, and the device we're using is the Galaxy S II.
>
>
> All the best
> -Alvaro.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en




-- 
Alvaro Victor Cavalcanti
[e-mail/chat] alvarovic...@gmail.com
[skype] alvarovictor
[twitter] alvarocavalcant
Systems Engineer / Aspiring Game Designer

------------------------------------------------------------------
Loodo - Um blog sobre Jogos e Game Design
                   www.loodo.com.br
------------------------------------------------------------------

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to