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();