Message544

Author retroj
Recipients dkettler
Date 2010-02-07.20:50:37
Content
I have in mind something that looks like this:

  var log_routes = {
      interactive_error: show_in_minibuffer,
      error: dumpln,
      warning: dumpln
  };

  function log (type, text, context) {
      var logfn = log_routes[type] || dumpln;
      logfn(text, context);
  }

Any given function in log_routes receives both the text and a context object.  The context object would
include properties like "buffer" and "window" when relevant.  This means that the interactive context,
"I", could be used also as a log context.
History
Date User Action Args
2010-02-07 20:50:37retrojsetmessageid: <1265575837.9.0.478916418559.issue232@servo.cc>
2010-02-07 20:50:37retrojsetrecipients: + dkettler
2010-02-07 20:50:37retrojlinkissue232 messages
2010-02-07 20:50:37retrojcreate