Skip to content

Instantly share code, notes, and snippets.

@nmschorr
Created September 23, 2015 23:47
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save nmschorr/a4b0ecb701807d2ffd9c to your computer and use it in GitHub Desktop.
class AlertThread extends Thread { // Dismiss the Firefox crash alert
public AlertThread (String tname) {
super(tname);
}
@Override
public void run(){
System.out.println("Inside run() of AlertThread method.");
try {
Thread.currentThread();
Thread.sleep(6000); // a wait to give time for the alert to appear
dismissFirefoxCrashAlert(); // closes Firefox error alerts
Thread.currentThread();
Thread.sleep(2000);
} catch (Exception e) { System.out.println(e); }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment