GreenScape
17th August 2010, 09:45
hello. i have an error(Segmentation fault) inside qt_metacall of my class:
int cl_StyledHeadersTableBase::qt_metacall(QMetaObject ::Call _c, int _id, void **_a)
{
_id = cl_TableViewBase::qt_metacall(_c, _id, _a);
if (_id < 0)
return _id;
if (_c == QMetaObject::InvokeMetaMethod) {
switch (_id) {
case 0: styleChanged(); break;
case 1: horizontalHeaderRequestContextMenu((*reinterpret_c ast< const QPoint(*)>(_a[1]))); break; // <- HERE
horizontalHeaderRequestContextMenu(QPoint*) is a virtual protected slot:
protected slots:
virtual void horizontalHeaderRequestContextMenu(const QPoint & pos);
but when i erase virtual keyword there is no such error.
i found that virtual slots are allowed (Qt doc (http://doc.trolltech.com/latest/qabstractitemview.html#dataChanged)).
so what am i do wrong?
thanks.
int cl_StyledHeadersTableBase::qt_metacall(QMetaObject ::Call _c, int _id, void **_a)
{
_id = cl_TableViewBase::qt_metacall(_c, _id, _a);
if (_id < 0)
return _id;
if (_c == QMetaObject::InvokeMetaMethod) {
switch (_id) {
case 0: styleChanged(); break;
case 1: horizontalHeaderRequestContextMenu((*reinterpret_c ast< const QPoint(*)>(_a[1]))); break; // <- HERE
horizontalHeaderRequestContextMenu(QPoint*) is a virtual protected slot:
protected slots:
virtual void horizontalHeaderRequestContextMenu(const QPoint & pos);
but when i erase virtual keyword there is no such error.
i found that virtual slots are allowed (Qt doc (http://doc.trolltech.com/latest/qabstractitemview.html#dataChanged)).
so what am i do wrong?
thanks.