Quote:
Originally Posted by Mackx
It was not a serious remark, just wanted to keep you busy for any future sleepless nights 
|
Well, now I'm fighting against my missing C++ skills...
How could I get a reference of ZLGtkApplicationWindow in menu.cpp?
EDIT: new code
In
ZLGtkApplicationWindow:ZLGtkApplicationWindow, I've added:
And in
menu.cpp:
Code:
static ZLGtkApplicationWindow *zlgtkappwin;
...
// initialise popup menu
void menu_init ( ZLGtkApplicationWindow *appwin )
{
...
zlgtkappwin = appwin;
...
And finally, in
menu.cpp menu_on_item_activated():
Code:
zlgtkappwin.application().doAction("toggleFullscreen");
but it doesn't work. Compiler shows this error:
Code:
Compiling dr-menu.o ...dr-menu.cpp: In function void menu_on_item_activated(const gchar*, const gchar*, const gchar*, const gchar*):
dr-menu.cpp:269: error: request for member application in zlgtkappwin, which is of non-class type ZLGtkApplicationWindow*
Any hint?
EDIT 2: It's compiling now, have to test on the emu ;-)
EDIT 3: It works! It works!
after some silly issues with the linker menu->fullscreen finally works, so the remaining items should be easy...
Iņigo