2003/06/12 17:57:37
[org.ibex.core.git] / src / org / xwt / MessageQueue.java
index 6de9185..cfc388b 100644 (file)
@@ -117,18 +117,18 @@ public class MessageQueue extends Thread {
                 if ((m != null && m == MessageQueue.currentlyPerforming) || MessageQueue.working) {
                     String what, where;
                     if (m != null && m instanceof ThreadMessage) {
-                        where = org.xwt.js.JS.getCurrentFunctionSourceName((ThreadMessage)m);
+                        where = org.xwt.js.Context.getSourceNameAndLineForThread((ThreadMessage)m);
                         what = "background thread";
                     } else if (m != null) {
-                        where = org.xwt.js.JS.getCurrentFunctionSourceName(MessageQueue.singleton);
+                        where = org.xwt.js.Context.getSourceNameAndLineForThread(MessageQueue.singleton);
                         what = "event trap";
                     } else {
-                        where = org.xwt.js.JS.getCurrentFunctionSourceName(MessageQueue.singleton);
+                        where = org.xwt.js.Context.getSourceNameAndLineForThread(MessageQueue.singleton);
                         what = "script";
                    }
-                    if (Log.on) Log.log(this, "note: executing same " + what +
-                                       " for " + (System.currentTimeMillis() - t) / 1000 + "s" +
-                                       " at " + where);
+                   long howlong = (System.currentTimeMillis() - t) / 1000;
+                   if (howlong >= 5)
+                       if (Log.on) Log.log(this, "note: executing same " + what + " for " + howlong + "s" + " at " + where);
                 } else {
                     m = MessageQueue.currentlyPerforming;
                     t = System.currentTimeMillis();