Avoid extra locking if queue is empty

This commit is contained in:
Charles J. Cliffe 2015-10-20 18:32:49 -04:00
parent b822704b0c
commit 71383b4cb6

View File

@ -109,7 +109,9 @@ void WaterfallCanvas::processInputQueue() {
void WaterfallCanvas::OnPaint(wxPaintEvent& WXUNUSED(event)) { void WaterfallCanvas::OnPaint(wxPaintEvent& WXUNUSED(event)) {
wxPaintDC dc(this); wxPaintDC dc(this);
processInputQueue(); if (visualDataQueue.size() > 0) {
processInputQueue();
}
const wxSize ClientSize = GetClientSize(); const wxSize ClientSize = GetClientSize();
long double currentZoom = zoom; long double currentZoom = zoom;