reshmasp
9th December 2010, 16:09
Hello All,
I had a question on how to display Qt menu's on Meego platform?
Following code snippet works on Symbian and Maemo platforms but doesn't work on Meego. Can anyone help with this issue?
QMenu* menu = new QMenu(this);
m_clearAllAction = new QAction(tr("Clear all history"), this);
connect(m_clearAllAction,SIGNAL(triggered()), this, SLOT(clearSearchHistory()) );
menu->addAction(m_clearAllAction);
menu->addAction(tr("About"), this, SLOT(about()));
m_clearAllAction->setEnabled(false);
QAction* myMenuKey = new QAction(tr("Options"), this);
myMenuKey->setSoftKeyRole(QAction::PositiveSoftKey);
myMenuKey->setMenu(menu);
addAction(myMenuKey );
QAction* exitAction = new QAction(tr("Exit"), this);
exitAction->setSoftKeyRole(QAction::NegativeSoftKey);
addAction(exitAction );
connect(exitAction, SIGNAL(triggered()), qApp, SLOT(quit()));
Thanks in advance,
Reshma
I had a question on how to display Qt menu's on Meego platform?
Following code snippet works on Symbian and Maemo platforms but doesn't work on Meego. Can anyone help with this issue?
QMenu* menu = new QMenu(this);
m_clearAllAction = new QAction(tr("Clear all history"), this);
connect(m_clearAllAction,SIGNAL(triggered()), this, SLOT(clearSearchHistory()) );
menu->addAction(m_clearAllAction);
menu->addAction(tr("About"), this, SLOT(about()));
m_clearAllAction->setEnabled(false);
QAction* myMenuKey = new QAction(tr("Options"), this);
myMenuKey->setSoftKeyRole(QAction::PositiveSoftKey);
myMenuKey->setMenu(menu);
addAction(myMenuKey );
QAction* exitAction = new QAction(tr("Exit"), this);
exitAction->setSoftKeyRole(QAction::NegativeSoftKey);
addAction(exitAction );
connect(exitAction, SIGNAL(triggered()), qApp, SLOT(quit()));
Thanks in advance,
Reshma