Fix some spelling errors

This commit is contained in:
Calcitem 2021-11-04 01:13:16 +08:00
parent 72a9ae9d74
commit 637080c176
12 changed files with 29 additions and 27 deletions

View File

@ -34,6 +34,8 @@ ignore$
(?:^|/)strings\.xml$
\.arb$
feedback_localization\.dart$
colors\.dart$
language_info\.dart$
zobrist\.dart$
release\.sh$
\.txt$

View File

@ -117,7 +117,7 @@
/// The game is drawn if there has been no removal in a specific number of moves.
#define RULE_50
//#define MESSAGEBOX_ENABLE
//#define MESSAGE_BOX_ENABLE
#ifdef DEBUG_MODE
#define DO_NOT_PLAY_SOUND
@ -130,7 +130,7 @@
#endif
#ifndef QT_MOBILE_APP_UI
#define SAVE_GAMEBOOK_WHEN_ACTION_NEW_TRIGGERED
#define SAVE_GAME_BOOK_WHEN_ACTION_NEW_TRIGGERED
#endif
//#define DO_NOT_PLAY_WIN_SOUND

View File

@ -23,7 +23,7 @@ import 'package:json_annotation/json_annotation.dart' show JsonSerializable;
/// Color Adapter
///
/// This adapter provides helper functions to be used with [JsonSerializable]
/// and is a general [TypeAdapter] to be used with Hive [Box]ses
/// and is a general [TypeAdapter] to be used with Hive [Box]es
class ColorAdapter extends TypeAdapter<Color> {
@override
final typeId = 6;

View File

@ -23,7 +23,7 @@ import 'package:json_annotation/json_annotation.dart' show JsonSerializable;
/// Locale Adapter
///
/// This adapter provides helper functions to be used with [JsonSerializable]
/// and is a general [TypeAdapter] to be used with Hive [Box]ses
/// and is a general [TypeAdapter] to be used with Hive [Box]es
class LocaleAdapter extends TypeAdapter<Locale?> {
@override
final typeId = 7;

View File

@ -44,7 +44,7 @@ class DatabaseV1 {
return File('${docDir.path}/$fileName');
}
/// loads the preferences from the old datastore
/// loads the preferences from the old data store
static Future<Map<String, dynamic>?> _loadFile(File _file) async {
debugPrint("$_tag Loading $_file ...");

View File

@ -102,7 +102,7 @@ Game::Game(
uint16_t clientPort = server->getPort() == 30001 ? 30002 : 30001;
client = new Client(nullptr, clientPort);
// The command line of AI andnetwork
// The command line of AI and network
connect(getClient(), SIGNAL(command(const string &, bool)),
this, SLOT(command(const string &, bool)));
#endif // NET_FIGHT_SUPPORT
@ -1280,7 +1280,7 @@ bool Game::command(const string &cmd, bool update /* = true */)
}
}
#ifdef MESSAGEBOX_ENABLE
#ifdef MESSAGE_BOX_ENABLE
message = QString::fromStdString(position.get_tips());
QMessageBox::about(NULL, "Game Result", message);
#endif

View File

@ -24,8 +24,8 @@
* But it doesn't look good to use one scene class to do so many control module operations
*/
#ifndef GAMECONTROLLER_H
#define GAMECONTROLLER_H
#ifndef GAME_H
#define GAME_H
#include <map>
#include <vector>
@ -554,4 +554,4 @@ inline void Game::set_start_time(int time)
startTime = time;
}
#endif // GAMECONTROLLER_H
#endif // GAME_H

View File

@ -16,8 +16,8 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef GRAPHICSVIEW_H
#define GRAPHICSVIEW_H
#ifndef GAME_VIEW_H
#define GAME_VIEW_H
#include <QGraphicsView>
@ -43,4 +43,4 @@ protected:
void resizeEvent(QResizeEvent *event) override;
};
#endif // GRAPHICSVIEW_H
#endif // GAME_VIEW_H

View File

@ -299,14 +299,14 @@ void MillGameWindow::initialize()
game, SLOT(actionPiece(QPointF)));
// Add a normal display label to the status bar
auto *statusBarlabel = new QLabel(this);
auto *statusBarLabel = new QLabel(this);
QFont statusBarFont;
statusBarFont.setPointSize(16);
statusBarlabel->setFont(statusBarFont);
ui.statusBar->addWidget(statusBarlabel);
statusBarLabel->setFont(statusBarFont);
ui.statusBar->addWidget(statusBarLabel);
connect(game, SIGNAL(statusBarChanged(QString)),
statusBarlabel, SLOT(setText(QString)));
statusBarLabel, SLOT(setText(QString)));
ruleActionList[game->getRuleIndex()]->setChecked(true);
game->setRule(game->getRuleIndex());
@ -640,7 +640,7 @@ void MillGameWindow::on_actionNew_N_triggered()
game->saveScore();
#ifdef SAVE_GAMEBOOK_WHEN_ACTION_NEW_TRIGGERED
#ifdef SAVE_GAME_BOOK_WHEN_ACTION_NEW_TRIGGERED
QString strDateTime = QDateTime::currentDateTime().toString("yyyy-MM-dd_hhmmss");
QString strDate = QDateTime::currentDateTime().toString("yyyy-MM-dd");
QString whoWin;
@ -669,7 +669,7 @@ void MillGameWindow::on_actionNew_N_triggered()
if (strlist->stringList().size() > 18) {
saveBook(path);
}
#endif /* SAVE_GAMEBOOK_WHEN_ACTION_NEW_TRIGGERED */
#endif /* SAVE_GAME_BOOK_WHEN_ACTION_NEW_TRIGGERED */
ui.actionAutoRun_A->setChecked(false);

View File

@ -16,8 +16,8 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef MANUALLISTVIEW
#define MANUALLISTVIEW
#ifndef MANUAL_LIST_VIEW_H
#define MANUAL_LIST_VIEW_H
#include <QListView>
#include <QMouseEvent>
@ -106,4 +106,4 @@ private:
bool newEmptyRow {false};
};
#endif // MANUALLISTVIEW
#endif // MANUAL_LIST_VIEW_H

View File

@ -16,8 +16,8 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef GAMEITEM_H
#define GAMEITEM_H
#ifndef PIECE_ITEM_H
#define PIECE_ITEM_H
#include <QObject>
#include <QGraphicsItem>
@ -130,4 +130,4 @@ private:
QColor removeLineColor;
};
#endif // GAMEITEM_H
#endif // PIECE_ITEM_H

View File

@ -131,12 +131,12 @@ void Server::sessionOpened()
return;
}
#ifdef MESSAGEBOX_ENABLE
#ifdef MESSAGE_BOX_ENABLE
QMessageBox::information(this, tr("Server"), tr("server Started %1.").arg(port));
#endif
}
else {
#ifdef MESSAGEBOX_ENABLE
#ifdef MESSAGE_BOX_ENABLE
QMessageBox::information(this, tr("Server"), tr("server Started %1.").arg(port));
#endif
}