Pointer to incomplete class type is not allowed
-
wrote on 18 Aug 2013, 17:14 last edited by
I removed menu bar and now I want to add function to move window... I did it in QtCreator and works perfect... Now trying to do it on Visual Studio 2012, but always get errors... Don't know how to fix this "Pointer to incomplete class type is not allowed" this errors are about "event" -> grey color on image... I hope someone can help me... Spent whole day trying to find solution...
-
wrote on 18 Aug 2013, 18:17 last edited by
As a "golden" rule you should look at the problems from top down, since the major errors are first. The remainder may be just some subsequent issues vanishing when the first problems are solved. Assuming that the top error is frameGeometry is undefined, you should solve this first.
-
wrote on 18 Aug 2013, 19:50 last edited by
I solved Pointer to incomplete class type is not allowed (added #include <QMouseEvent>), but don't know how to solve frameGeometry and move...
-
The error is pretty explicit, these two functions don't exist in your class.
So the real question here is: why did you subclass QMouseEvent ?
-
wrote on 18 Aug 2013, 21:58 last edited by
Oh my god... I can't believe I spent whole day for damn easy thing...
SGalast thank you for that.... I was including wrong libraries...
By the way, how can I make this to be in use only for frame??? I have main window and frame on the top of the window... I'd like to move window around only with frame...
-
You're welcome !
I'm sorry but I don't understand your last question
-
wrote on 18 Aug 2013, 23:09 last edited by
Below is image of my app... This thing in back is frame and I added my buttons to it (exit, minimize)... Right now, I can my function works for whole window -> I can move window around if I press frame or just blue window... I'd like to set it to move around only when I press on frame
-
Did you try to discard the mouse events for the blue window ?
-
wrote on 21 Aug 2013, 17:02 last edited by
How can I do that?????
-
You could install an event filter
10/10