Exemple #1
0
Fichier : map.cpp Projet : Ra8/RAP
void Map::acceptKeyEvent(QKeyEvent* event){
    if(event->key()==Qt::Key_F){
        toggleFlag();
    } else if(event->key()==Qt::Key_N && role>0){
        role=role%polices.size()+1;
    } else if(event->key()==Qt::Key_X){
        string fn="accounts/savedGames/"+accountID;
        cout << fn << endl;
        saveToFile(fn);
    } else if(event->key()==Qt::Key_P) {
        emit TOGGLEPAUSESIGNAL();
    } else if(event->key()==Qt::Key_E) {
        escapeFromGate();
    }
}
Exemple #2
0
/**
 * The undoable thing gets activated if it was undone and 
 * deactivated otherwise.
 */
void RS_Undoable::changeUndoState() {
    toggleFlag(RS2::FlagUndone);
	undoStateChanged(isUndone());
}
void CalibrationEngine::setFlag(int flag, bool value) {
	toggleFlag(flag);
}
void CellStateComponent::rightClickAction()
{
	toggleFlag();
}