Fix #8037 - bug on zoom
[roobuilder] / src / Builder4 / GtkView.vala
index dfed016..6cc6fa6 100644 (file)
@@ -578,7 +578,7 @@ public class Xcls_GtkView : Object
                        // set gobject values
                        new Xcls_sourceviewscroll( _this );
                        this.el.append( _this.sourceviewscroll.el );
-                       var child_2 = new Xcls_Box12( _this );
+                       var child_2 = new Xcls_Box13( _this );
                        child_2.ref();
                        this.el.append( child_2.el );
                }
@@ -643,7 +643,7 @@ public class Xcls_GtkView : Object
                        this.el.set_buffer ( _this.buffer.el  );
                        new Xcls_keystate( _this );
                        this.el.add_controller(  _this.keystate.el );
-                       var child_3 = new Xcls_EventControllerScroll37( _this );
+                       var child_3 = new Xcls_EventControllerScroll12( _this );
                        child_3.ref();
                        this.el.add_controller(  child_3.el );
 
@@ -1008,7 +1008,7 @@ public class Xcls_GtkView : Object
                // user defined functions
        }
 
-       public class Xcls_EventControllerScroll37 : Object
+       public class Xcls_EventControllerScroll12 : Object
        {
                public Gtk.EventControllerScroll el;
                private Xcls_GtkView  _this;
@@ -1018,7 +1018,7 @@ public class Xcls_GtkView : Object
                public double distance;
 
                // ctor
-               public Xcls_EventControllerScroll37(Xcls_GtkView _owner )
+               public Xcls_EventControllerScroll12(Xcls_GtkView _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.EventControllerScroll( Gtk.EventControllerScrollFlags.VERTICAL );
@@ -1036,11 +1036,11 @@ public class Xcls_GtkView : Object
                                //GLib.debug("scroll %f",  dy);
                                
                                this.distance += dy;
-                               if (this.distance < 1) {
+                                if (this.distance < -1) {
                                        BuilderApplication.settings.editor_font_size ++;
                                        this.distance = 0;
                                }
-                               if (this.distance > -1) {
+                               if (this.distance > 1) {
                                        BuilderApplication.settings.editor_font_size --;
                                        this.distance = 0;
                                }
@@ -1054,7 +1054,7 @@ public class Xcls_GtkView : Object
 
 
 
-       public class Xcls_Box12 : Object
+       public class Xcls_Box13 : Object
        {
                public Gtk.Box el;
                private Xcls_GtkView  _this;
@@ -1063,7 +1063,7 @@ public class Xcls_GtkView : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Box12(Xcls_GtkView _owner )
+               public Xcls_Box13(Xcls_GtkView _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Box( Gtk.Orientation.HORIZONTAL, 0 );
@@ -1081,7 +1081,7 @@ public class Xcls_GtkView : Object
                        this.el.append( _this.nextBtn.el );
                        new Xcls_backBtn( _this );
                        this.el.append( _this.backBtn.el );
-                       var child_5 = new Xcls_MenuButton18( _this );
+                       var child_5 = new Xcls_MenuButton19( _this );
                        child_5.ref();
                        this.el.append( child_5.el );
                }
@@ -1111,7 +1111,7 @@ public class Xcls_GtkView : Object
                        this.el.hexpand = true;
                        this.el.placeholder_text = "Press enter to search";
                        this.el.search_delay = 3;
-                       var child_1 = new Xcls_EventControllerKey14( _this );
+                       var child_1 = new Xcls_EventControllerKey15( _this );
                        child_1.ref();
                        this.el.add_controller(  child_1.el );
 
@@ -1159,7 +1159,7 @@ public class Xcls_GtkView : Object
                        
                }
        }
-       public class Xcls_EventControllerKey14 : Object
+       public class Xcls_EventControllerKey15 : Object
        {
                public Gtk.EventControllerKey el;
                private Xcls_GtkView  _this;
@@ -1168,7 +1168,7 @@ public class Xcls_GtkView : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_EventControllerKey14(Xcls_GtkView _owner )
+               public Xcls_EventControllerKey15(Xcls_GtkView _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.EventControllerKey();
@@ -1318,7 +1318,7 @@ public class Xcls_GtkView : Object
                // user defined functions
        }
 
-       public class Xcls_MenuButton18 : Object
+       public class Xcls_MenuButton19 : Object
        {
                public Gtk.MenuButton el;
                private Xcls_GtkView  _this;
@@ -1328,7 +1328,7 @@ public class Xcls_GtkView : Object
                public bool always_show_image;
 
                // ctor
-               public Xcls_MenuButton18(Xcls_GtkView _owner )
+               public Xcls_MenuButton19(Xcls_GtkView _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.MenuButton();
@@ -1363,14 +1363,14 @@ public class Xcls_GtkView : Object
                        // my vars (dec)
 
                        // set gobject values
-                       var child_1 = new Xcls_Box20( _this );
+                       var child_1 = new Xcls_Box21( _this );
                        child_1.ref();
                        this.el.set_child ( child_1.el  );
                }
 
                // user defined functions
        }
-       public class Xcls_Box20 : Object
+       public class Xcls_Box21 : Object
        {
                public Gtk.Box el;
                private Xcls_GtkView  _this;
@@ -1379,7 +1379,7 @@ public class Xcls_GtkView : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Box20(Xcls_GtkView _owner )
+               public Xcls_Box21(Xcls_GtkView _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );