Add feedback if zooming out is not possible (#884)

* Add feedback if zooming out is not possible

* Main: Cuddle else

Co-authored-by: Daniel Foré <daniel@elementary.io>
This commit is contained in:
Marius Meisenzahl 2020-07-22 19:07:14 +02:00 committed by GitHub
parent 203e93c4e2
commit e8801734d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -80,11 +80,13 @@ namespace Gala.Plugins.Zoom {
void zoom (bool @in) {
// Nothing to do if zooming out of our bounds is requested
if (current_zoom <= 1.0f && !@in)
return;
else if (current_zoom >= 10.0f && @in)
if (current_zoom <= 1.0f && !@in) {
Gdk.beep ();
return;
} else if (current_zoom >= 10.0f && @in) {
Gdk.beep ();
return;
}
var wins = wm.ui_group;