Commit fff1403c authored by Pino Toscano's avatar Pino Toscano
Browse files

i18n fixes

svn path=/trunk/KDE/kdegames/ksirk/; revision=916287
parent 004008dc
......@@ -92,7 +92,7 @@
<item>
<widget class="QLabel" name="label_8" >
<property name="text" >
<string>State :</string>
<string>State:</string>
</property>
</widget>
</item>
......
......@@ -104,7 +104,7 @@ void NewGameDialogImpl::slotCancel()
void NewGameDialogImpl::slotHelp()
{
kDebug() << "KPlayerSetupDialog slotHelp not already implemented";
KMessageBox::sorry(this, i18n("Help currently unavailable."),i18n("KsirK - No help !"));
KMessageBox::sorry(this, i18n("Help currently unavailable."),i18n("KsirK - No help!"));
}
void NewGameDialogImpl::fillSkinsCombo()
......@@ -129,7 +129,7 @@ void NewGameDialogImpl::fillSkinsCombo()
{
KMessageBox::error(0,
i18n("Skins directory not found - Verify your installation\nProgram cannot continue"),
i18n("Fatal Error !"));
i18n("Fatal Error!"));
exit(2);
}
kDebug() << "Got skins dir name: " << skinsDirName;
......
......@@ -19,7 +19,7 @@
<enum>QFrame::NoFrame</enum>
</property>
<property name="text" >
<string>Player number %1, please enter your name and choose your nation :</string>
<string>Player number %1, please enter your name and choose your nation:</string>
</property>
<property name="wordWrap" >
<bool>true</bool>
......@@ -59,7 +59,7 @@ Choose one of them. It will be your nation during the game</string>
<item row="2" column="0" colspan="2" >
<widget class="QLabel" name="passwordLabel" >
<property name="text" >
<string>Enter your password :</string>
<string>Enter your password:</string>
</property>
<property name="wordWrap" >
<bool>false</bool>
......
......@@ -47,7 +47,7 @@ Choose one of them. It will be your nation during the game</string>
<item row="2" column="0" >
<widget class="QLabel" name="passwordLabel" >
<property name="text" >
<string>Enter your password :</string>
<string>Enter your password:</string>
</property>
<property name="wordWrap" >
<bool>false</bool>
......
......@@ -89,7 +89,7 @@
<enum>QFrame::NoFrame</enum>
</property>
<property name="text" >
<string>%1 won ! Do you want to play again ?</string>
<string>%1 won! Do you want to play again?</string>
</property>
<property name="buddy" stdset="0" >
<cstring></cstring>
......
......@@ -1277,7 +1277,7 @@ bool GameAutomaton::joinNetworkGame()
{
kDebug();
if (stateName() == "INIT"
|| (KMessageBox::warningContinueCancel(m_game,i18n("Do you really want to end your current game and join another ?"),i18n("New game confirmation"),KStandardGuiItem::yes()) == KMessageBox::Continue))
|| (KMessageBox::warningContinueCancel(m_game,i18n("Do you really want to end your current game and join another?"),i18n("New game confirmation"),KStandardGuiItem::yes()) == KMessageBox::Continue))
{
// Set default network parameter
QString host = "localhost";
......@@ -1318,7 +1318,7 @@ bool GameAutomaton::joinNetworkGame()
bool GameAutomaton::joinJabberGame(const QString& nick)
{
if (stateName() == "INIT" || (KMessageBox::warningContinueCancel(m_game,i18n("Do you really want to end your current game and join another ?"),i18n("New game confirmation"),KStandardGuiItem::yes()) == KMessageBox::Continue))
if (stateName() == "INIT" || (KMessageBox::warningContinueCancel(m_game,i18n("Do you really want to end your current game and join another?"),i18n("New game confirmation"),KStandardGuiItem::yes()) == KMessageBox::Continue))
{
// stop game
setGameStatus(KGame::End);
......@@ -1591,13 +1591,13 @@ void GameAutomaton::changePlayerName(Player* player)
bool computer = player->isAI();
bool found = true;
KMessageBox::information(m_game, i18n("Please choose another name"), i18n("KsirK - Name already used !"));
KMessageBox::information(m_game, i18n("Please choose another name"), i18n("KsirK - Name already used!"));
while(found)
{
bool emptyName = true;
while (emptyName)
{
mes = i18n("Player number %1, what's your name ?", 1);
mes = i18n("Player number %1, what's your name?", 1);
bool network = false;
QString password;
KPlayerSetupDialog(this, m_game->theWorld(), 1, nomEntre, network, password, computer, nations, nationName, m_game).exec();
......@@ -1658,7 +1658,7 @@ void GameAutomaton::changePlayerNation(Player* player)
QString nomEntre = player->name();
bool computer = player->isAI();
KMessageBox::information(m_game, i18n("Please choose another nation"), i18n("KsirK - Nation already used !"));
KMessageBox::information(m_game, i18n("Please choose another nation"), i18n("KsirK - Nation already used!"));
bool network = false;
QString password = false;
KPlayerSetupDialog(this, m_game->theWorld(), 1, nomEntre, network, password, computer, nations, nationName, m_game).exec();
......@@ -1747,7 +1747,7 @@ void GameAutomaton::slotConnectionToServerBroken()
if (m_state != GAME_OVER)
{
if (KMessageBox::questionYesNoCancel(m_game,
i18n("KsirK - Lost connection to server !\nWhat do you want to do ?"),
i18n("KsirK - Lost connection to server!\nWhat do you want to do?"),
i18n("Starting a new game or exit."),
KGuiItem(i18n("New Game")),
KGuiItem(i18n("Exit")),
......@@ -1776,7 +1776,7 @@ void GameAutomaton::slotConnectionToClientBroken(KMessageIO *)
{
KMessageBox::information(m_game,
i18n("Lost connection to a client.\nFor the moment, you can only save the game and start a new one or quit.\nThis will be improved in a future version."),
i18n("KsirK - Lost connection to client !"));
i18n("KsirK - Lost connection to client!"));
switch ( KMessageBox::warningYesNo( m_game, i18n("Do want to save your game?")) )
{
case KMessageBox::Yes :
......@@ -1939,7 +1939,7 @@ void GameAutomaton::countriesDistribution()
KMessageParts messageParts;
messageParts
<< pm
<< I18N_NOOP("%1 : %2 armies to place")
<< I18N_NOOP("%1: %2 armies to place")
<< nextPlayerName
<< QString::number( initialNbArmies - distributedCountriesNumberMap[nextPlayerName]);
kDebug() << "Message parts size= " << messageParts.size() << endl;
......@@ -2021,7 +2021,7 @@ void GameAutomaton::displayGoals()
KMessageBox::information(
game(),
i18n("%1, your goal will be displayed. Please<br>"
"make sure that no other player can see it !",(*it)->name()),
"make sure that no other player can see it!",(*it)->name()),
i18n("KsirK - Displaying Goal"));
dynamic_cast<Player*>(*it)->goal().show();
}
......@@ -2334,7 +2334,7 @@ void GameAutomaton::slotNetworkData(int msgid, const QByteArray &buffer, quint32
}
break;
case ShowArmiesToPlace:
messageParts << pm << I18N_NOOP("%1 : %2 armies to place") << (currentPlayer()-> name())
messageParts << pm << I18N_NOOP("%1: %2 armies to place") << (currentPlayer()-> name())
<< QString::number(currentPlayer()-> getNbAvailArmies());
m_game->broadcastChangeItem(messageParts, ID_STATUS_MSG2);
m_game->showMessage(i18n("Now, place your armies in your countries<br>by clicking in the target countries."));
......@@ -2437,7 +2437,7 @@ void GameAutomaton::slotNetworkData(int msgid, const QByteArray &buffer, quint32
{
if (explosing != 0 && explosing != 1 && explosing != 2)
{
KMessageBox::information(m_game, i18n("Problem : no one destroyed"), i18n("Ksirk - Error !"));
KMessageBox::information(m_game, i18n("Problem : no one destroyed"), i18n("Ksirk - Error!"));
}
else
{
......@@ -2486,7 +2486,7 @@ void GameAutomaton::slotNetworkData(int msgid, const QByteArray &buffer, quint32
case InvalidPassword:
if (receiver == gameId())
{
KMessageBox::information(m_game, i18n("You entered an invalid password.\nPlease try again."), i18n("KsirK - Invalid password !"));
KMessageBox::information(m_game, i18n("You entered an invalid password.\nPlease try again."), i18n("KsirK - Invalid password!"));
m_game->setupOneWaitedPlayer();
}
break;
......@@ -2688,8 +2688,8 @@ void GameAutomaton::actionNextPlayer()
|| currentPlayer()->isAI()
|| m_currentPlayerPlayed
|| (KMessageBox::questionYesNo (m_game,
i18n("%1, you have not played anything this turn.\nDo you really want to lose your turn ?",m_currentPlayer),
i18n("Really Next Player ?")) == KMessageBox::Yes) )
i18n("%1, you have not played anything this turn.\nDo you really want to lose your turn?",m_currentPlayer),
i18n("Really Next Player?")) == KMessageBox::Yes) )
{
QByteArray buffer;
QDataStream stream(&buffer, QIODevice::WriteOnly);
......
......@@ -155,7 +155,7 @@ QString Goal::message(int displayType) const
QList<QString>::const_iterator it, it_end, it_next;
if(type()==NoGoal) {
QString mes = i18n("You must conquer the World !");
QString mes = i18n("You must conquer the World!");
return mes;
}
else
......@@ -194,7 +194,7 @@ QString Goal::message(int displayType) const
}
else
{
res = res.subs(i18n("Error : no player to destroy"));
res = res.subs(i18n("Error: no player to destroy"));
}
break;
case Goal::Countries:
......
......@@ -127,7 +127,7 @@ ONU::ONU(GameAutomaton* automaton,
{
KMessageBox::error(0,
i18n("Pool filename not found\nProgram cannot continue"),
i18n("Error !"));
i18n("Error!"));
exit(2);
}
m_map = QPixmap();
......@@ -144,7 +144,7 @@ ONU::ONU(GameAutomaton* automaton,
{
KMessageBox::error(0,
i18n("Map mask image not found\nProgram cannot continue"),
i18n("Error !"));
i18n("Error!"));
exit(2);
}
kDebug() << "Loading map mask file: " << mapMaskFileName;
......
......@@ -1524,7 +1524,7 @@ void JabberAccount::slotGroupChatError (const XMPP::Jid &jid, int error, const Q
case JabberClient::NicknameConflict:
{
bool ok;
QString nickname = KInputDialog::getText(i18n("Error trying to join %1 : nickname %2 is already in use", jid.node(), jid.resource()),
QString nickname = KInputDialog::getText(i18n("Error trying to join %1: nickname %2 is already in use", jid.node(), jid.resource()),
i18n("Provide your nickname"),
QString(),
&ok);
......
......@@ -280,7 +280,7 @@ void JabberContact::handleIncomingMessage (const XMPP::Message & message)
{
QString room=message.invite();
QString originalBody=message.body().isEmpty() ? QString() :
i18n( "The original message is : <i>\" %1 \"</i><br />" , Qt::escape(message.body()));
i18n( "The original message is: <i>\" %1 \"</i><br />" , Qt::escape(message.body()));
QString mes=i18n("<qt><i>%1</i> has invited you to join the conference <b>%2</b><br />%3<br />"
"If you want to accept and join, just <b>enter your nickname</b> and press ok<br />"
"If you want to decline, press cancel</qt>",
......
......@@ -54,8 +54,8 @@ bool GameXmlHandler::startElement( const QString & namespaceURI, const QString &
if (fv!=wfv)
{
KMessageBox::sorry(0,
i18n("Wrong save game format. Waited %1 and got %2 !",QString(SAVE_GAME_FILE_FORMAT_VERSION),atts.value("formatVersion")),
i18n("KsirK - Cannot load !"));
i18n("Wrong save game format. Waited %1 and got %2!",QString(SAVE_GAME_FILE_FORMAT_VERSION),atts.value("formatVersion")),
i18n("KsirK - Cannot load!"));
return false;
}
......
......@@ -511,7 +511,7 @@ qreal AnimSprite::getMaxX() const
return backGnd-> pixmap().width();
else
{
KMessageBox::error(0, i18n("Cannot find Max X for sprite: no background !"), i18n("Error !"));
KMessageBox::error(0, i18n("Cannot find Max X for sprite: no background!"), i18n("Error!"));
exit(2);
}
}
......@@ -526,7 +526,7 @@ qreal AnimSprite::getMaxY() const
return backGnd-> pixmap().height();
else
{
KMessageBox::error(0, i18n("Cannot find Max Y for sprite: no background !"), i18n("Error !"));
KMessageBox::error(0, i18n("Cannot find Max Y for sprite: no background!"), i18n("Error!"));
exit(2);
}
}
......
......@@ -693,7 +693,7 @@ void KGameWindow::initCombatMovement()
sndRoulePath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/roll.wav");
if (sndRoulePath.isNull())
{
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error !"));
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -808,7 +808,7 @@ void KGameWindow::initCombatMovement()
sndRoulePath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/roll.wav");
if (sndRoulePath.isNull())
{
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error !"));
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -853,7 +853,7 @@ void KGameWindow::animCombat()
if (sndCanonPath.isNull())
{
KMessageBox::error(0,
i18n("Sound cannon not found - Verify your installation<br>Program cannot continue"), i18n("Error !"));
i18n("Sound cannon not found - Verify your installation<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -928,7 +928,7 @@ void KGameWindow::animExplosion(int who)
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -948,7 +948,7 @@ void KGameWindow::animExplosion(int who)
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -988,7 +988,7 @@ void KGameWindow::animExplosion(int who)
/*QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1049,7 +1049,7 @@ void KGameWindow::animExplosionForArena()
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1086,7 +1086,7 @@ void KGameWindow::animExplosionForArena()
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1121,7 +1121,7 @@ void KGameWindow::animExplosionForArena()
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1175,7 +1175,7 @@ void KGameWindow::animExplosionForArena()
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1212,7 +1212,7 @@ void KGameWindow::animExplosionForArena()
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1246,7 +1246,7 @@ void KGameWindow::animExplosionForArena()
QString sndCrashPath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/crash.wav");
if (sndCrashPath.isNull())
{
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error !"));
KMessageBox::information(this, i18n("Sound crash not found - Verify your installation\nProgram cannot continue"), i18n("KsirK - Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1290,7 +1290,7 @@ void KGameWindow::initCombatBringBackForArena(Country *attackingCountry, Country
if ((NKD != 0)&&(NKA != 0)) who = 2;
else if (NKA != 0) who = 0;
else if (NKD != 0) who = 1;
else KMessageBox::information(0, i18n("Problem : no one destroyed"));
else KMessageBox::information(0, i18n("Problem: no one destroyed"));
//CannonSprite *newSprite;
AnimSprite* newSprite;
......@@ -1409,7 +1409,7 @@ void KGameWindow::initCombatBringBackForArena(Country *attackingCountry, Country
QString sndRoulePath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/roll.wav");
if (sndRoulePath.isNull())
{
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error !"));
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......@@ -1486,7 +1486,7 @@ void KGameWindow::initCombatBringBackForArena(Country *attackingCountry, Country
QString sndRoulePath = m_dirs-> findResource("appdata", m_automaton->skin() + "/Sounds/roll.wav");
if (sndRoulePath.isNull())
{
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error !"));
KMessageBox::error(0, i18n("Sound roule not found - Verify your installation<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
if (KsirkSettings::soundEnabled())
......
......@@ -150,7 +150,7 @@ KGameWindow::KGameWindow(QWidget* parent) :
QString iconFileName = m_dirs-> findResource("appdata", m_automaton->skin() + "/Images/soldierKneeling.png");
if (iconFileName.isNull())
{
KMessageBox::error(0, i18n("Cannot load icon<br>Program cannot continue"), i18n("Error !"));
KMessageBox::error(0, i18n("Cannot load icon<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
QPixmap icon(iconFileName);
......@@ -340,7 +340,7 @@ void KGameWindow::initActions()
// kDebug() << "Trying to load button image file: " << imageFileName;
if (imageFileName.isNull())
{
KMessageBox::error(0, i18n("Cannot load button image %1<br>Program cannot continue",QString("jabber.png")), i18n("Error !"));
KMessageBox::error(0, i18n("Cannot load button image %1<br>Program cannot continue",QString("jabber.png")), i18n("Error!"));
exit(2);
}
m_jabberAction = new QAction(QIcon(QPixmap(imageFileName)), i18n("Play over Jabber"), this);
......@@ -357,7 +357,7 @@ void KGameWindow::initActions()
// kDebug() << "Trying to load button image file: " << imageFileName;
if (imageFileName.isNull())
{
KMessageBox::error(0, i18n("Cannot load button image %1<br>Program cannot continue",QString(CM_NEWNETGAME)), i18n("Error !"));
KMessageBox::error(0, i18n("Cannot load button image %1<br>Program cannot continue",QString(CM_NEWNETGAME)), i18n("Error!"));
exit(2);
}
KAction* newSocketAction = new KAction(KIcon(QPixmap(imageFileName)), i18n("New Standard TCP/IP Network Game"), this);
......@@ -374,7 +374,7 @@ void KGameWindow::initActions()
// kDebug() << "Trying to load button image file: " << imageFileName;
if (imageFileName.isNull())
{
KMessageBox::error(0, i18n("Cannot load button image %1<br>Program cannot continue",QString(CM_NEWNETGAME)), i18n("Error !"));
KMessageBox::error(0, i18n("Cannot load button image %1<br>Program cannot continue",QString(CM_NEWNETGAME)), i18n("Error!"));
exit(2);
}
KAction* joinAction = new KAction(KIcon(QPixmap(imageFileName)),
......@@ -527,7 +527,7 @@ void KGameWindow::newSkin(const QString& onuFileName)
if (onuDefinitionFileName.isEmpty())
{
KMessageBox::error(0,
i18n("World definition file not found - Verify your installation<br>Program cannot continue"), i18n("Error !"));
i18n("World definition file not found - Verify your installation<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
kDebug() << "Got World definition file name: " << onuDefinitionFileName;
......@@ -731,7 +731,7 @@ void KGameWindow::initView()
QString iconFileName = m_dirs-> findResource("appdata", m_automaton->skin() + "/Images/soldierKneeling.png");
if (iconFileName.isNull())
{
KMessageBox::error(0, i18n("Cannot load icon<br>Program cannot continue"), i18n("Error !"));
KMessageBox::error(0, i18n("Cannot load icon<br>Program cannot continue"), i18n("Error!"));
exit(2);
}
// to port : still necessary ?
......@@ -824,7 +824,7 @@ bool KGameWindow::attackEnd()
showMessage(i18n("%1, you are defeated! Bye, bye...",oldOwner->name()), 10, ForceShowing);
/* KMessageBox::information(this,
i18n("%1, you are defeated! Bye, bye...",oldOwner->name()),
i18n("KsirK - Game Over !"));*/
i18n("KsirK - Game Over!"));*/
if (m_automaton->isAdmin())
{
kDebug() << "Removing player " << oldOwner-> name();
......@@ -874,7 +874,7 @@ bool KGameWindow::attackEnd()
QDataStream stream(&buffer, QIODevice::WriteOnly);
m_automaton->sendMessage(buffer,ClearHighlighting);
KMessageParts messageParts;
messageParts << I18N_NOOP("%1 : it is up to you again") << currentPlayer()-> name();
messageParts << I18N_NOOP("%1: it is up to you again") << currentPlayer()-> name();
broadcastChangeItem(messageParts, ID_STATUS_MSG2, false);
}
}
......@@ -1079,7 +1079,7 @@ bool KGameWindow::queryClose()
if ((m_automaton->state() == GameAutomaton::INIT) || (m_automaton->state() == GameAutomaton::INTERLUDE))
{
switch ( KMessageBox::warningYesNo( this, i18n("Do you want to quit the game ?")) )
switch ( KMessageBox::warningYesNo( this, i18n("Do you want to quit the game?")) )
{
case KMessageBox::Yes :
break;
......@@ -1255,7 +1255,7 @@ void KGameWindow::displayDefenseWindow()
QPushButton * defAuto = new QPushButton (i18n("Defend-Auto"));
QLabel * labDef = new QLabel ();
labDef->setText(i18n("<font color=\"red\">%1</font> attacks you from <font color=\"red\">%2</font> with %3 armies !<br> How do you want to defend <font color=\"blue\">%4</font> ?",
labDef->setText(i18n("<font color=\"red\">%1</font> attacks you from <font color=\"red\">%2</font> with %3 armies!<br> How do you want to defend <font color=\"blue\">%4</font>?",
this->firstCountry()->owner()->name(),
this->firstCountry()->name(),
QString::number(this->firstCountry()->owner()->getNbAttack()),
......@@ -1444,7 +1444,7 @@ bool KGameWindow::setupOnePlayer()
bool emptyName = true;
while (emptyName)
{
mes = i18n("Player number %1, what's your name ?", 1);
mes = i18n("Player number %1, what's your name?", 1);
bool network = true;
KPlayerSetupDialog(m_automaton, m_theWorld, 1, nomEntre, network, password, computer, nations, nationName, this).exec();
kDebug() << "After KPlayerSetupDialog. name: " << nomEntre;
......@@ -1822,20 +1822,20 @@ bool KGameWindow::isMoveValid(const QPointF& point)
}
else if ( m_firstCountry->owner() != currentPlayer() )
{
messageParts << I18N_NOOP("You are not the owner of the first country: %1 !") << m_firstCountry->name();
messageParts << I18N_NOOP("You are not the owner of the first country: %1!") << m_firstCountry->name();
}
else if ( secondCountry->owner() != currentPlayer() )
{
messageParts << I18N_NOOP("You are not the owner of the second country: %1 !") << secondCountry->name();
messageParts << I18N_NOOP("You are not the owner of the second country: %1!") << secondCountry->name();
}
else if (m_firstCountry == secondCountry)
{
messageParts << I18N_NOOP("You are trying to move armies from %1 to itself !") << m_firstCountry->name();
messageParts << I18N_NOOP("You are trying to move armies from %1 to itself!") << m_firstCountry->name();
}
else if (!m_firstCountry->communicateWith(secondCountry))
{
messageParts
<< I18N_NOOP("%1 is not a neighbour of %2 !")
<< I18N_NOOP("%1 is not a neighbour of %2!")
<< secondCountry-> name()
<< m_firstCountry-> name();
}
......@@ -1863,31 +1863,31 @@ bool KGameWindow::isFightValid(const QPointF& point)
else if ( m_firstCountry->owner() != currentPlayer() )
{
kDebug() << "You are not the owner of the first country: "<< m_firstCountry->name();
messageParts << I18N_NOOP("You are not the owner of the first country: %1 !")
messageParts << I18N_NOOP("You are not the owner of the first country: %1!")
<< m_firstCountry->name();
}
else if ( secondCountry->owner() == currentPlayer() )
{
kDebug() << "You are the owner of the second country: " << secondCountry->name();
messageParts << I18N_NOOP("You are the owner of the second country: %1 !") << secondCountry->name();
messageParts << I18N_NOOP("You are the owner of the second country: %1!") << secondCountry->name();
}
else if (m_firstCountry == secondCountry)
{
kDebug() <<"You are trying to move armies from "<<m_firstCountry->name()<<" to itself ";
messageParts << I18N_NOOP("You are trying to move armies from %1 to itself !") << m_firstCountry->name();
messageParts << I18N_NOOP("You are trying to move armies from %1 to itself!") << m_firstCountry->name();
}
else if (!m_firstCountry->communicateWith(secondCountry))
{
kDebug() << secondCountry-> name() << "is not a neighbour of " << secondCountry-> name();
messageParts
<< I18N_NOOP("%1 is not a neighbour of %2 !")
<< I18N_NOOP("%1 is not a neighbour of %2!")
<< secondCountry-> name()
<< m_firstCountry-> name();
}
else
{
kDebug() << "Ready to fight !";
messageParts << I18N_NOOP("Ready to fight !");
messageParts << I18N_NOOP("Ready to fight!");
res = true;
}
broadcastChangeItem(messageParts, ID_STATUS_MSG2, false);
......@@ -1979,7 +1979,7 @@ bool KGameWindow::attacker(const QPointF& point)
KMessageParts messageParts;
if (clickedCountry == 0)
{
messageParts << I18N_NOOP("<font color=\"orange\">No country here !</font>");
messageParts << I18N_NOOP("<font color=\"orange\">No country here!</font>");
broadcastChangeItem(messageParts, ID_STATUS_MSG2, false);
clearHighlighting();
return false;
......@@ -1987,14 +1987,14 @@ bool KGameWindow::attacker(const QPointF& point)
if (clickedCountry-> owner() != currentPlayer())
{
messageParts << I18N_NOOP("<font color=\"orange\">You are not the owner of %1 !</font>") << clickedCountry-> name();
messageParts << I18N_NOOP("<font color=\"orange\">You are not the owner of %1!</font>") << clickedCountry-> name();
clearHighlighting();
broadcastChangeItem(messageParts, ID_STATUS_MSG2, false);
return false;
}
else if (clickedCountry-> nbArmies() <= currentPlayer()-> getNbAttack())
{
messageParts << I18N_NOOP("<font color=\"orange\">There is only %1 armies in %2 !</font>")
messageParts << I18N_NOOP("<font color=\"orange\">There is only %1 armies in %2!</font>")
<< QString::number(clickedCountry-> nbArmies())
<< clickedCountry-> name();
clearHighlighting();
......@@ -2198,7 +2198,7 @@ bool KGameWindow::playerPutsArmy(const QPointF& point, bool removable)
KMessageParts messageParts;
messageParts
<< pm
<< I18N_NOOP("%1 : %2 armies to place")
<< I18N_NOOP("%1: %2 armies to place")
<< currentPlayer()-> name()
<< QString::number(nbAvailArmies);
broadcastChangeItem(messageParts, ID_STATUS_MSG2, false);
......@@ -2264,7 +2264,7 @@ bool KGameWindow::playerPutsInitialArmy(const QPointF& point)
/* KMessageParts messageParts;
messageParts
<< pm
<< I18N_NOOP("%1 : %2 armies to place") << ((Player*)(*it))-> name()
<< I18N_NOOP("%1: %2 armies to place") << ((Player*)(*it))-> name()
<< QString::number(((Player*)(*it))-> getNbAvailArmies());
broadcastChangeItem(messageParts, ID_STATUS_MSG2);*/
/* m_nbAvailArmies = ((Player*)(*it))-> getNbAvailArmies();
......@@ -2295,7 +2295,7 @@ bool KGameWindow::playerPutsInitialArmy(const QPointF& point)
getRightDialog()->updateRecycleDetails(clickedCountry,false,(quint32) ((GameLogic::Player*)(currentPlayer()))->getNbAvailArmies());
QPixmap pm = currentPlayer()->getFlag()->image(0);
KMessageParts messageParts;
messageParts << pm << I18N_NOOP("%1 : %2 armies to place")
messageParts << pm << I18N_NOOP("%1: %2 armies to place")
<< currentPlayer()-> name()
<< QString::number((quint32) ((GameLogic::Player*)(currentPlayer()))->getNbAvailArmies());
changeItem(messageParts, ID_STATUS_MSG2, false);
......@@ -2332,7 +2332,7 @@ bool KGameWindow::playerRemovesArmy(const QPointF& point)