Re: [Vala] Purple.CoreUiOps



Here is the full error:
app.vala:83.4-83.27: error: Invalid type for member `input_add'
  input_add = my_input_add,

82:  Purple.EventLoopUiOps glib_eventloops = Purple.EventLoopUiOps() {
83:  input_add = my_input_add,
84:  input_remove = GLib.Source.remove,
85:  input_get_error = null,
86:  timeout_add = GLib.Timeout.add,
87:  timeout_add_seconds = GLib.Timeout.add_seconds,
88:  timeout_remove = GLib.Source.remove
89:  };

And here is my method:
28: uint my_input_add(int fd, Purple.InputCondition condition,
Purple.InputFunction func)

The full source code, compile line, errors and purple vapi is available at:
https://gist.github.com/1870407

On Monday, February 20, 2012, Luca Bruno wrote:

On Mon, Feb 20, 2012 at 7:47 AM, Joseph Montanez <jmontanez gorilla3d com<javascript:_e({}, 'cvml', 
'jmontanez gorilla3d com');>
wrote:

and changed it too:
       [CCode (cheader_filename = "purple.h")]
       [Compact]
       public struct EventLoopUiOps {
               public weak GLib.Callback input_add;
               public weak GLib.Callback input_get_error;
               public weak GLib.Callback input_remove;
               public weak GLib.Callback timeout_add;
               public weak GLib.Callback timeout_add_seconds;
               public weak GLib.Callback timeout_remove;
       }


[Compact] has no effect on structs.

I get "Invalid type for member `input_add'". I am going to take a wild
guess and say that in purple.vapi I need to add some [something that
fixed this] to let me add parameters to a callback?


Please, always paste the full error.

--
www.debian.org - The Universal Operating System



-- 
Joseph Montanez
Web Developer
Gorilla3D
Design, Develop, Deploy


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]