No tests at this time. If it works for you in FF, then run with it. On Thu, Dec 9, 2010 at 4:12 AM, Ittai <[email protected]> wrote:
> Fred, > Thanks a lot for your answers. > I will extend the DivLogger. > In the off chance I will have some free time, is there a set of tests > the WindowLogger needs to pass to change it's state, which I can use > to see if the problem(s) still exist? > Is it just a functional test of this specific issue (i.e. just try it > in FF and if it works then it is sovled)? > If you'd rather let sleeping dogs lie that's ok. > > Ittai > On Dec 8, 7:20 am, Fred Sauer <[email protected]> wrote: > > Ittai, > > > > The WindowLogger is experimental because I could never get it to work > right > > in FF with "new windows are opened in tabs" active. Don't know if that > > problem still exists or not. If it works for you, feel free to use it. > > > > The filtering of log messages happens, as you saw in the source, > centrally. > > IOW, the setting of separate log levels per logger is not supported. > Here's > > a workaround which might get you what you want without too much trouble. > > > > Disable the DivLogger (even though you'll use it below): > > > > <set-property name="log_DivLogger" value="DISABLED" /> > > > > Create a class which extends DivLogger and which filters the way you > want: > > > > class MyDivLogger extends DivLogger { > > > > @Override > > > > public void log(LogRecord record) { > > > > if (record.getLevel() >= Log.LOG_LEVEL_ERROR) { > > > > super.log(record); > > > > } > > > > } > > > > } > > > > Then register your custom logger: > > > > Log.addLogger(new MyDivLogger()); > > > > and test: > > > > Log.trace("xxx"); > > > > Log.debug("xxx"); > > > > Log.info("xxx"); > > > > Log.warn("xxx"); > > > > Log.fatal("xxx"); > > > > Bonus, override setCurrentLogLevel() to allow MyDivLogger to be more > > configurable on what it filters. > > > > Fred > > > > > > > > > > > > On Mon, Dec 6, 2010 at 9:56 AM, Ittai <[email protected]> wrote: > > > Hi Fred, > > > I tried to play around with having both window logger and div logger > > > active at the same time but with different levels and was > > > unsuccessfull. > > > Is it supported? > > > Basically what I'd like to have is to have my module load with a > > > hidden div logger which constantly logs error and up and to have the > > > window logger open and close based on key combinations (already > > > implemented those handlers) with it's log level as debug > > > I tried compiling the module with debug (so the compiler won't ommit > > > those statements) and then onModuleLoad call > > > Log.getLogger(DivLogger.class).setCurrentLogLevel(Log.ERROR) > > > but that only disabled the buttons of the div logger while it not kept > > > the messages from being logged in it. > > > The viewed behaviour was also consistent with the sources I peaked at. > > > The other issue I saw in the sources is that the WindowLogger already > > > has the ability to be programatically closed it's just hidden > > > (private) and only used when the module is closed. Is there a specific > > > reason for this decision? > > > > > Thanks a lot for reading so far, > > > Ittai > > > > > -- > > > You received this message because you are subscribed to the Google > Groups > > > "gwt-log" group. > > > To post to this group, send email to [email protected]. > > > To unsubscribe from this group, send email to > > > [email protected]<gwt-log%[email protected]> > <gwt-log%[email protected]<gwt-log%[email protected]> > > > > > . > > > For more options, visit this group at > > >http://groups.google.com/group/gwt-log?hl=en. > > > > -- > > Fred Sauer > > Developer Advocate > > Google Inc. > > 1600 Amphitheatre Parkway > > Mountain View, CA 94043 > > [email protected] Hide quoted text - > > > > - Show quoted text - > > -- > You received this message because you are subscribed to the Google Groups > "gwt-log" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<gwt-log%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/gwt-log?hl=en. > > -- Fred Sauer Developer Advocate Google Inc. 1600 Amphitheatre Parkway Mountain View, CA 94043 [email protected] -- You received this message because you are subscribed to the Google Groups "gwt-log" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/gwt-log?hl=en.
