Pass Cairo context down to child elements instead of recreating it.

This commit is contained in:
Adam Reichold
2015-12-05 09:14:41 +01:00
parent 48f0225104
commit 333f9013dd
5 changed files with 7 additions and 13 deletions

View File

@@ -705,14 +705,13 @@ void FileBrowserEntry::updateCursor (int x, int y)
}
}
void FileBrowserEntry::draw ()
void FileBrowserEntry::draw (Cairo::RefPtr<Cairo::Context> cc)
{
ThumbBrowserEntryBase::draw ();
ThumbBrowserEntryBase::draw (cc);
if (state == SRotateSelecting) {
Cairo::RefPtr<Cairo::Context> cr = parent->getDrawingArea ()->get_window()->create_cairo_context();
drawStraightenGuide (cr);
drawStraightenGuide (cc);
}
}