Skip to content

Commit c6636b9

Browse files
Add more brackets
1 parent 117cd0c commit c6636b9

3 files changed

Lines changed: 22 additions & 11 deletions

File tree

src/Faction.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,12 @@ const QMap<Faction::GameObject, GameObjectTypes>& Faction::GetTechTree() const {
2929
const QVector<QVector<Faction::Action>> Faction::GetKeyboardLayoutsByObjectName(const QString& objName) const
3030
{
3131
for(const Faction::GameObject& go : techTree.keys())
32+
{
3233
if(go.iconName == objName)
34+
{
3335
return go.keyboardLayouts;
36+
}
37+
}
3438

3539
return {};
3640
}

src/GUI/EditorWindow.cpp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,10 @@ void EditorWindow::SetGameObjectList(const QString& factionShortName)
249249
.scaledToHeight(PROGRAM_CONSTANTS->ICON_SCALING_HEIGHT, Qt::SmoothTransformation));
250250

251251
// If there no objects by type - then skip
252-
if (goMap.keys(objectType).isEmpty()) continue;
252+
if (goMap.keys(objectType).isEmpty())
253+
{
254+
continue;
255+
}
253256

254257
// Append entities to the section
255258
for (const auto& go : goMap.keys(objectType))
@@ -291,8 +294,12 @@ void EditorWindow::SetHotkeysPanels()
291294

292295
// Skip if it's the top level section item
293296
for (int i = 0; i < pEntitiesTreeWidget->topLevelItemCount(); ++i)
297+
{
294298
if (pItem == pEntitiesTreeWidget->topLevelItem(i))
299+
{
295300
return;
301+
}
302+
}
296303

297304
const QPair<QString, QString> specialItemInfo = pItem->data(0, Qt::UserRole).value<QPair<QString, QString>>();
298305

src/GUI/Translations/ru.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -77,23 +77,23 @@
7777
</message>
7878
<message>
7979
<location filename="../EditorWindow.cpp" line="222"/>
80-
<location filename="../EditorWindow.cpp" line="535"/>
80+
<location filename="../EditorWindow.cpp" line="542"/>
8181
<source>Settings</source>
8282
<translation>Настройки</translation>
8383
</message>
8484
<message>
8585
<location filename="../EditorWindow.cpp" line="226"/>
86-
<location filename="../EditorWindow.cpp" line="496"/>
86+
<location filename="../EditorWindow.cpp" line="503"/>
8787
<source>About</source>
8888
<translation>О программе</translation>
8989
</message>
9090
<message>
91-
<location filename="../EditorWindow.cpp" line="356"/>
91+
<location filename="../EditorWindow.cpp" line="363"/>
9292
<source>Layout %1</source>
9393
<translation>Раскладка %1</translation>
9494
</message>
9595
<message>
96-
<location filename="../EditorWindow.cpp" line="474"/>
96+
<location filename="../EditorWindow.cpp" line="481"/>
9797
<source>&lt;p&gt;Authors: %1&lt;br&gt;Version: %2&lt;br&gt;&lt;br&gt;Program licensed with %3&lt;br&gt;&lt;br&gt;GitHub repository:&lt;br&gt;%4&lt;br&gt;&lt;br&gt;Support development:&lt;br&gt;%5&lt;/p&gt;</source>
9898
<translation>&lt;p&gt;Авторы: %1&lt;br&gt;Версия: %2&lt;br&gt;&lt;br&gt;Программа лицензирована под %3&lt;br&gt;&lt;br&gt;Репозиторий на GitHub:&lt;br&gt;%4&lt;br&gt;&lt;br&gt;Поддержать разработку:&lt;br&gt;%5&lt;/p&gt;</translation>
9999
</message>
@@ -118,32 +118,32 @@
118118
<translation type="vanished">Поддержать разработку:</translation>
119119
</message>
120120
<message>
121-
<location filename="../EditorWindow.cpp" line="566"/>
121+
<location filename="../EditorWindow.cpp" line="573"/>
122122
<source>Changes has been saved to the file:</source>
123123
<translation>Изменения были сохранены в файл:</translation>
124124
</message>
125125
<message>
126-
<location filename="../EditorWindow.cpp" line="582"/>
126+
<location filename="../EditorWindow.cpp" line="589"/>
127127
<source>Saved as:</source>
128128
<translation>Сохранено как:</translation>
129129
</message>
130130
<message>
131-
<location filename="../EditorWindow.cpp" line="614"/>
131+
<location filename="../EditorWindow.cpp" line="621"/>
132132
<source>Opening selected file</source>
133133
<translation>Открываем выбранный файл</translation>
134134
</message>
135135
<message>
136-
<location filename="../EditorWindow.cpp" line="620"/>
136+
<location filename="../EditorWindow.cpp" line="627"/>
137137
<source>Changing editor language</source>
138138
<translation>Изменяем язык редактора</translation>
139139
</message>
140140
<message>
141-
<location filename="../EditorWindow.cpp" line="591"/>
141+
<location filename="../EditorWindow.cpp" line="598"/>
142142
<source>Binary files</source>
143143
<translation>Двоичные файлы</translation>
144144
</message>
145145
<message>
146-
<location filename="../EditorWindow.cpp" line="592"/>
146+
<location filename="../EditorWindow.cpp" line="599"/>
147147
<source>Any files</source>
148148
<translation>Все файлы</translation>
149149
</message>

0 commit comments

Comments
 (0)