3333
3434import java .io .File ;
3535import java .io .IOException ;
36+ import java .io .InputStream ;
3637import java .util .*;
3738import java .util .regex .Matcher ;
3839import java .util .regex .Pattern ;
@@ -256,6 +257,7 @@ public boolean isEmulator() {
256257
257258 public void setPackageName (String pkgName ) {
258259 packageName = pkgName ;
260+ System .out .println ("setting package name to " + packageName );
259261 }
260262
261263 // I/Process ( 9213): Sending signal. PID: 9213 SIG: 9
@@ -267,12 +269,10 @@ public void setPackageName(String pkgName) {
267269 private class LogLineProcessor implements LineProcessor {
268270 public void processLine (final String line ) {
269271 final LogEntry entry = new LogEntry (line );
270- // System.err .println("***************************************************");
272+ // System.out .println("***************************************************");
271273// System.out.println(line);
272- // System.err.println(activeProcesses);
273- // System.err.println(entry.message);
274-
275- System .out .println (line );
274+ // System.out.println(activeProcesses);
275+ // System.out.println(entry.message);
276276
277277 if (entry .message .startsWith ("PROCESSING" )) {
278278 // Old start/stop process detection, does not seem to work anymore.
@@ -391,7 +391,7 @@ private void reportStackTrace(final LogEntry entry) {
391391
392392 void initialize () throws IOException , InterruptedException {
393393 adb ("logcat" , "-c" );
394- final String [] cmd = generateAdbCommand ("logcat" );
394+ final String [] cmd = generateAdbCommand ("logcat" , "-v" , "brief" );
395395 final String title = PApplet .join (cmd , ' ' );
396396 logcat = Runtime .getRuntime ().exec (cmd );
397397 ProcessRegistry .watch (logcat );
@@ -403,9 +403,6 @@ void initialize() throws IOException, InterruptedException {
403403 public void run () {
404404 try {
405405 logcat .waitFor ();
406- // final int result = logcat.waitFor();
407- // System.err.println("AndroidDevice: " + getId() + " logcat exited "
408- // + (result == 0 ? "normally" : "with status " + result));
409406 } catch (final InterruptedException e ) {
410407 System .err
411408 .println ("AndroidDevice: logcat process monitor interrupted" );
0 commit comments