FREE REGISTRATION LINK "http://makemoney.usersboard.com" WHICH FORUM ALLOWED EXTERNAL LINK

by xomba.bd » Thu, 22 Apr 2010 00:36:12 GMT


Sponsored Links
 FREE REGISTRATION LINK " http://makemoney.usersboard.com " WHICH FORUM
ALLOWED EXTERNAL LINK



FREE REGISTRATION LINK


 http://makemoney.usersboard.com/profile.forum?mode=register 

--



Other Threads

1. new screen on button click

Hello,

I am trying to follow a tutorial to learn how to get to a new screen
on a button click. The issue I feel I am facing is that in this
tutorial they have a file named main.java, firstly I don't have such a
file. I think I named the file as name1.java and on this screen i have
everything going on including this button I am trying to make. So I m
really confused as in this article below they have the main.java file
and from that file they are moving to screen 1 and screen 2. Is it so
important to have a main.java from where we branch the two activities?
So tired and confused, please help

http://www.barebonescoder.com/2010/05/android-development-adding-screens-button-handlers/

-- 

2. Unit testing a class that uses android.os.Handler

I have a class that uses a Handler for a timed, asynchronous activity.
Something like this:

public class SampleClass {
  private static final long DELAY = 30000;
  private boolean isRunning = false;
  private Handler handler = new Handler();

  public start() {
    if (!isRunning) {
      isRunning = true;
      handler.post(new Thread(task));
    }
  }

  public stop() {
    isRunning = false;
  }

  private Runnable task = new Runnable() {
    public void run() {
      if (!isRunning) {
        return;
      }

      // Do some tasks
      handler.postDelayed(new Thread(this), DELAY);
    }
  }
}


I am trying to write a unit test (without having to implement an
activity that instantiates the class) but I can't seem to get the
items that are posted to the MessageQueue to ever be fired. Inheriting
from junit.framework.TestCase doesn't work, but then there wouldn't be
a MessageQueue for the handler, I'd expect (although, there's no
error, but the Runnable never gets called). I tried inheriting the
test class from AndroidTestCase and ApplicationTestCase<Application>
but neither of those works, even though the former is supposed to
provide a Context and the latter "all the life cycle of an
application."

Anyone have any pointers?

--
Jeremy Wadsack

-- 

3. Question For All Android Developer

4. Custom ListView Contain ImageView + TextView + CheckBox for selected Row

5. Can I turn the flash on?

6. AlertDialog within a TabActivity

7. Custom title bar with TextView and id @android:id/title does not inherit/use android:label from manifest!