From 034886732674ee71d25a48c3c925d04dceedd120 Mon Sep 17 00:00:00 2001 From: Andy2 Date: Wed, 2 Mar 2011 18:59:35 -0800 Subject: [PATCH] add printStack() --- .../XWords4/src/org/eehouse/android/xw4/Utils.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/Utils.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/Utils.java index 4c5c8d944..d45a83c6b 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/Utils.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/Utils.java @@ -83,6 +83,16 @@ public class Utils { } } // logf + public static void printStack() + { + if ( s_doLog ) { + StackTraceElement[] trace = Thread.currentThread().getStackTrace(); + for ( int ii = 0; ii < trace.length; ++ii ) { + Utils.logf( "ste %d: %s", ii, trace[ii].toString() ); + } + } + } + public static void notImpl( Context context ) { CharSequence text = "Feature coming soon";