Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-6474

Compile error in qguistatemachine.cpp - QContextMenuEvent not defined

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 4.6.1
    • 4.6.0
    • Core: State Machine
    • None
    • e8b3defc466fff9110ee00b6e730d405cde52abc

    Description

      qguistatemachine.cpp does not compile if QT is configured without some features. Namely if QT_NO_CONTEXTMENU or QT_NO_STATUSTIP is defined. We use such configuration when building QtMoko (formerly Qtopia or QtExtended) for Openmoko phones.

      Attached is patch that fixes it.

      Error message follows:

      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp: In function 'QEvent* cloneEvent(QEvent*)':
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: expected type-specifier before 'QContextMenuEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: cannot convert 'int*' to 'QEvent*' in return
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: expected ';' before 'QContextMenuEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: expected type-specifier before 'QContextMenuEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: expected `>' before 'QContextMenuEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: expected `(' before 'QContextMenuEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: 'QContextMenuEvent' was not declared in this scope
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:188: error: expected primary-expression before '>' token
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: expected type-specifier before 'QStatusTipEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: cannot convert 'int*' to 'QEvent*' in return
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: expected ';' before 'QStatusTipEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: expected type-specifier before 'QStatusTipEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: expected `>' before 'QStatusTipEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: expected `(' before 'QStatusTipEvent'
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: 'QStatusTipEvent' was not declared in this scope
      /home/radek/qte/qtmoko/qtopiacore/qt/src/gui/statemachine/qguistatemachine.cpp:242: error: expected primary-expression before '>' token
      make[2]: Leaving directory `/home/radek/qte/build/qtopiacore/target/src/gui'
      make[1]: Leaving directory `/home/radek/qte/build/qtopiacore/target'
      make[2]: *** [.obj/release-shared-emb-arm/qguistatemachine.o] Error 1
      make[1]: *** [sub-gui-make_default-ordered] Error 2

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kenthans Kent Hansen (Inactive)
            radekp Radek Polak
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes