mirror of
https://github.com/rodamaral/lsnes.git
synced 2025-04-02 10:42:15 -04:00
17 lines
389 B
C++
Executable file
17 lines
389 B
C++
Executable file
void pItem::setText(const string &text) {
|
|
qtAction->setText(QString::fromUtf8(text));
|
|
}
|
|
|
|
void pItem::constructor() {
|
|
qtAction = new QAction(0);
|
|
connect(qtAction, SIGNAL(triggered()), SLOT(onActivate()));
|
|
}
|
|
|
|
void pItem::destructor() {
|
|
if(action.state.menu) action.state.menu->remove(item);
|
|
delete qtAction;
|
|
}
|
|
|
|
void pItem::onActivate() {
|
|
if(item.onActivate) item.onActivate();
|
|
}
|