summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDavid King <amigadave@amigadave.com>2013-12-12 10:43:35 +0000
committerDavid King <amigadave@amigadave.com>2013-12-12 10:43:35 +0000
commit3cb01fcb31ef43cd08c0154a37f4c4224cb70e4b (patch)
tree979adb4b1568a1256920936c6e0ff31695695434 /src
parenta149d17cc4e6f1b529e3c50cb0644a9a148117ac (diff)
downloadcheese-3cb01fcb31ef43cd08c0154a37f4c4224cb70e4b.tar.gz
Fix an empty last page in the effects selector
If there were exactly the same number of effects available as were shown in the effects selector, an empty last page was shown. Fix a condition to test that there are more spaces for effects in the selector than there are available effects. Fixes bug 720178.
Diffstat (limited to 'src')
-rw-r--r--src/cheese-window.vala3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cheese-window.vala b/src/cheese-window.vala
index 5096a1a2..313c33cc 100644
--- a/src/cheese-window.vala
+++ b/src/cheese-window.vala
@@ -1015,7 +1015,8 @@ public class Cheese.MainWindow : Gtk.ApplicationWindow
private bool is_next_effects_page ()
{
- return current_effects_page != effects_manager.effects.length () / EFFECTS_PER_PAGE;
+ // Calculate the number of effects visible up to the current page.
+ return (current_effects_page + 1) * EFFECTS_PER_PAGE < effects_manager.effects.length ();
}
private bool is_previous_effects_page ()