Community
Participate
Working Groups
I was debugging a problem and needed to stick a breakpoint on TreeViewer#setExpanded. When I did this, I would constantly get hits from the log view which seems to refresh when the Eclipse window is activated. I closed the view but the problem persisted. Ihad to close all perspectives to get the log view to clear. Has the LogView been registered as a perspective listener? If so, it should be removed when the view is closed.
from the drop down menu of the log view, there should be an option to turn off the 'Activate on new events' feature. does that work for you?
After some playing around, I am not able to reproduce the problem. However, I noticed that for each log entry, the view fires an asyncExec. I have some UI code loaded from HEAD which is logging a lot of errors so it is likely that there was a backlog of asyncExecs being processed after the view was closed. What we usually do in cases like this is keep of queue of pending entries and have a single job that processes them. This allows for batched processing when a large number of errors are being logged and makes it possible to cancel the job if the view is closed.
hi Jacek :)
Created attachment 82397 [details] mylyn/context/zip
Created attachment 84393 [details] patch Batch entries when LogView is closed (actually hidden). When view goes back to life (Window->Show View->Log View), all batched entries are added in a Job. As a result there are no more asyncExec's as long as view is closed. And there is only one when view is displayed for first time. Brian or Chris, please review :)
Created attachment 84394 [details] mylyn/context/zip
Will do Jacek :)
Created attachment 84412 [details] mylyn/context/zip
Great patch Jacek, I made some minor modifications but other than that, things look good.
Created attachment 84413 [details] mylyn/context/zip