Problem Querying Bonobo_Unknown



Hi list,

I am new to Bonobo, so forgive me if this question seems stupid. I
haven't been able to find an answer on the list, and the docs are a
little tricky for a newbie like me ;)

I'm trying to embed an EOG control in a window, and here is what I'm
doing so far:

Bonobo_Control mycontrol;
Bonobo_PersistStream pstream;

mycontrol = bonobo_get_object ("OAFIID:GNOME_EOG_Control",
"Bonobo/Control", &ev );
pstream = (Bonobo_PersistStream) Bonobo_Unknown_queryInterface
(mycontrol, "IDL:Bonobo/PersistStream:1.0", &ev );
if (BONOBO_EX(&ev) || (pstream == CORBA_OBJECT_NIL)) {
        g_error ("Failed to get pstream"); return -1; }

For some reason, I cannot get pstream to work with the
Bonobo_Unknown_queryInterface call. If I use Bonobo_PersistFile instead,
it works correctly, but I read in the API that PersistFile is deprecated
in favour of PersistStream. Plus the file I am retrieving is not
available via the VFS interface.

GNOME_EOG_Control implements the PersistStream interface, according to
its server file.

Any insights or suggestions would be greatly appreciated.

ADB




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