If you don't want to write a whole vapi you can do the following after the Display has been initialized:
[CCode (cname="gdk_wayland_display_get_type")] extern Type get_wayland_type(); Type display_type = Gdk.Display.get_default().get_type(); Type wayland_type = get_wayland_type(); if(display_type.is_a(wayland_type)) { ... disable key binding here... } 2016-12-12 13:48 GMT-08:00 rastersoft <ras...@rastersoft.com>: > Before someone says "using GDK_IS_WAYLAND_DISPLAY", my question is how > to do that on Vala, because I can't find those macros in the VAPI files. > > > El 12/12/16 a las 21:21, rastersoft escribió: > > Hi all: > > > > I want my program Terminus to be able to run under Wayland. > > Unfortunately, by default tries to bind to a key, which Wayland doesn't > > support and produces a core dump. > > > > It is possible to detect if my code is running under Wayland to disable > > the key binding? > > > > Thanks. > > > > -- > Nos leemos > RASTER (Linux user #228804) > ras...@rastersoft.com http://www.rastersoft.com > > _______________________________________________ > vala-list mailing list > vala-list@gnome.org > https://mail.gnome.org/mailman/listinfo/vala-list > -- Chris Daley Pacific Northwest e: chebiza...@gmail.com w: http://chrisdaley.biz m: +1-971-703-9251 s: chebizarro tw: chebizarro tz: PDT _______________________________________________ vala-list mailing list vala-list@gnome.org https://mail.gnome.org/mailman/listinfo/vala-list