[android-developers] Re: AsyncTask never calls onProgressUpdate
Why are you starting yet another thread in doInBackground()? The method doInBackground is already called in a separate (background) thread. No need to yet spawn another one. -- 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
Re: [android-developers] Re: AsyncTask never calls onProgressUpdate
Hi, The authenticate method takes a long time, and I want to update progress while that's happening like this: Authenticating . Authenticating . . Authenticating . . . Authenticating . . . . Authenticating So I created a thread to add a dot to my TextView every 1/4 second. Mark Murphy's solution seems to be functioning properly. My error was assuming that protected void onProgressUpdate() was equivalent to protected void onProgressUpdate(Void... voids) as well as missing some @Overrides. Thanks all, -jm On Mon, Jan 16, 2012 at 2:24 PM, Streets Of Boston flyingdutc...@gmail.com wrote: Why are you starting yet another thread in doInBackground()? The method doInBackground is already called in a separate (background) thread. No need to yet spawn another one. -- 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 -- 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
Re: [android-developers] Re: AsyncTask never calls onProgressUpdate
... and this: textViewAuthenticating = (TextView) dialog.findViewById(R.id.TextViewAuthentication); belongs in onPreExecute, or elsewhere on the UI thread, *not* in doInBackground. 16 января 2012 г. 23:24 пользователь Streets Of Boston flyingdutc...@gmail.com написал: Why are you starting yet another thread in doInBackground()? The method doInBackground is already called in a separate (background) thread. No need to yet spawn another one. -- 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 -- 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
Re: [android-developers] Re: AsyncTask never calls onProgressUpdate
How do I pass my Dialog to onPreExecute? -jm 2012/1/16 Kostya Vasilyev kmans...@gmail.com: ... and this: textViewAuthenticating = (TextView) dialog.findViewById(R.id.TextViewAuthentication); belongs in onPreExecute, or elsewhere on the UI thread, *not* in doInBackground. 16 января 2012 г. 23:24 пользователь Streets Of Boston flyingdutc...@gmail.com написал: Why are you starting yet another thread in doInBackground()? The method doInBackground is already called in a separate (background) thread. No need to yet spawn another one. -- 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 -- 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 -- 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
Re: [android-developers] Re: AsyncTask never calls onProgressUpdate
A setDialog() method in your subclass, just to throw out an idea. Or lazy initialization in onProgressUpdate. Or create the dialog in onPreExecute rather than outside the task 16 января 2012 г. 23:44 пользователь John-Marc Desmarais j...@ieee.org написал: How do I pass my Dialog to onPreExecute? -jm 2012/1/16 Kostya Vasilyev kmans...@gmail.com: ... and this: textViewAuthenticating = (TextView) dialog.findViewById(R.id.TextViewAuthentication); belongs in onPreExecute, or elsewhere on the UI thread, *not* in doInBackground. -- 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