Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. deleting a widget from creator leaves a warning from .moc file
Forum Updated to NodeBB v4.3 + New Features

deleting a widget from creator leaves a warning from .moc file

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
3 Posts 2 Posters 754 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    tony67
    wrote on last edited by tony67
    #1

    Hi All,
    In creator forms I've deleted a widget, this works fine except it leaves an error in the moc file, I've commented out the error ( the tableView_2 ) but I still have a warning from the moc function declaration. How can I get rid of the warning its from void **_a, I tried commenting out void **_a but this just causes a host of errors.
    Can anyone advise please

    void Game_Edit_Dialog::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
    {
        if (_c == QMetaObject::InvokeMetaMethod) {
            Reels_Edit_Dialog *_t = static_cast<Game_Edit_Dialog *>(_o);
            switch (_id) {
            case 0: _t->on_pushButton_clicked(); break;
            case 1: _t->on_pushButton_2_clicked(); break;
            case 2: _t->on_pushButton_3_clicked(); break;
           // case 3: _t->on_tableView_2_customContextMenuRequested((*reinterpret_cast< const QPoint(*)>(_a[1]))); break;
            default: ;
            }
        }
    }
    
    1 Reply Last reply
    0
    • kshegunovK Offline
      kshegunovK Offline
      kshegunov
      Moderators
      wrote on last edited by
      #2

      @tony67
      Hello,
      What's the error? The function you've provided is generated automatically by the meta-object compiler (moc) and even if you change something in that file, it will be generated anew on the next call to qmake. This code is basically what calls your slots. Try rerunning qmake for your project and do a full rebuild.

      Kind regards.

      Read and abide by the Qt Code of Conduct

      1 Reply Last reply
      0
      • T Offline
        T Offline
        tony67
        wrote on last edited by
        #3

        Thanks you put me onto the right path, I did a full rebuild and the case 2 reappeared. I then remembered I'd set a slot in designer for the context menu. This had put a slot function in my header. Deleting this sorted everything.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved