bugfix for issue #569: thumbs disappear when +/- button is pressed

An implementation for redrawNeed() was lacking in the derived class BatchQueue:
when updateImage called it there was no effect.
This commit is contained in:
ffsup2
2011-05-13 23:19:07 +02:00
parent 446cddcc80
commit 90b9c1a827
4 changed files with 10 additions and 12 deletions

View File

@@ -639,16 +639,6 @@ void FileBrowser::notifySelectionListener () {
}
}
void FileBrowser::redrawNeeded (ThumbBrowserEntryBase* entry) {
if (entry->insideWindow (0, 0, internal.get_width(), internal.get_height())) {
if (!internal.isDirty ()) {
internal.setDirty ();
internal.queue_draw ();
}
}
}
void FileBrowser::redrawNeeded (LWButton* button) {
queue_draw ();

View File

@@ -116,7 +116,6 @@ class FileBrowser : public ThumbBrowserBase, public LWButtonListener {
void openDefaultViewer (int destination);
void redrawNeeded (ThumbBrowserEntryBase* entry);
void thumbRearrangementNeeded ();
void _thumbRearrangementNeeded ();

View File

@@ -566,5 +566,14 @@ int ThumbBrowserBase::getEffectiveHeight() {
return h;
}
void ThumbBrowserBase::redrawNeeded (ThumbBrowserEntryBase* entry) {
if (entry->insideWindow (0, 0, internal.get_width(), internal.get_height())) {
if (!internal.isDirty ()) {
internal.setDirty ();
internal.queue_draw ();
}
}
}

View File

@@ -116,7 +116,7 @@ class ThumbBrowserBase : public Gtk::VBox {
virtual bool keyPressed (GdkEventKey* event) {return true;}
virtual void selectionChanged () {}
virtual void redrawNeeded (ThumbBrowserEntryBase* entry) {}
virtual void redrawNeeded (ThumbBrowserEntryBase* entry);
virtual void thumbRearrangementNeeded () {}
Gtk::Widget* getDrawingArea () { return &internal; }