Skip to content
Commit 7193f050 authored by Martin Pitt's avatar Martin Pitt
Browse files

Add type checking to positional Gtk.Box and Gtk.Window ctor arguments

Gtk.Box and Gtk.Window are base classes of a lot of widgets. Avoid confusion
when trying to create a subclass of them through the GObject constructor with
positional arguments by at least verifying that their type is right. Otherwise
you can do things like

  chooser = Gtk.FileChooserWidget(Gtk.FileChooserAction.SELECT_FOLDER)

which succeeds, but does not have the desired effect (it sets the "homogenous"
property of the Gtk.Box superclass instead).

https://bugzilla.gnome.org/show_bug.cgi?id=711487
parent 79aea265
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment