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

CLONE -QAction::softKeyRole function misbehaves in Symbian Emulator binary

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 4.7.1
    • 4.7.0
    • None
    • None
    • Symbian S60 5th Edition Emulator
    • 19ebb3f5b2f599018594e9f0dd3b9de81f584262

    Description

      QAction::softKeyRole returns a wrong value when QAction::NegativeSoftKey is set.
      This only happens with the emulator binaries provided in the qt-symbian-opensource-4.7.0-rc1-s60.exe, the target build does not have this problem.

      Example code:

      QAction* action = new QAction(this);
      action->setSoftKeyRole(QAction::NegativeSoftKey);

      QAction::SoftKeyRole role = action->softKeyRole(); // returns -2
      if(action->softKeyRole() != QAction::NegativeSoftKey)

      { qDebug() << "ooops!"; }

      As a consequence it's not possible to bind an action to the right softkey.

      In the disassembly the code looks wrong:

      0x013b4a43 <QAction::softKeyRole>: mov eax,dword ptr [eax+0x9c]
      0x013b4a49 <QAction::softKeyRole+6>: sal eax,0x11
      0x013b4a4c <QAction::softKeyRole+9>: sar eax,0x1e
      }
      0x013b4a4f <QAction::softKeyRole+12>: leave
      0x013b4a50 <QAction::softKeyRole+13>: ret near

      Why is this a "shift arithetically right" instead of a logical shift? Compiler/build issue?

      Attachments

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

        Activity

          People

            jasmcdon Jason McDonald (Closed Nokia Identity. Please assign to "macadder" instead) (Inactive)
            bartelmus Christoph Bartelmus
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes