Re: [Vala] How to cast Gdk.EventKey to Gdk.Event ?

2011-11-26 Thread Tal Hadad
Gdk.Event* real_e = (Gdk.Event*)(e); It's tested. Gdk.Event* is an unowned Gdk.Event, only different is syntax: (Gdk.Event)instance = (Gdk.Event*)-instance Tal Date: Fri, 25 Nov 2011 23:48:59 -0500 From: shawn.p.hu...@gmail.com To: vala-list@gnome.org Subject: [Vala] How to cast Gdk.EventKey

Re: [Vala] How to cast Gdk.EventKey to Gdk.Event ?

2011-11-26 Thread Peng Huang
Nov 2011 23:48:59 -0500 From: shawn.p.hu...@gmail.com To: vala-list@gnome.org Subject: [Vala] How to cast Gdk.EventKey to Gdk.Event ? How to cast Gdk.EventKey to Gdk.Event in vala? some code like, but it does not compile. 100 public override bool key_release_event(Gdk.EventKey e) { 101

[Vala] How to cast Gdk.EventKey to Gdk.Event ?

2011-11-25 Thread Peng Huang
How to cast Gdk.EventKey to Gdk.Event in vala? some code like, but it does not compile. 100 public override bool key_release_event(Gdk.EventKey e) { 101 if (m_primary_modifier != KeybindingManager.keyval_to_modifier(e.keyval)) 102 return true; 103 104 if