Skip to content

Commit e82726b

Browse files
authored
Attorney Online 2.11 Release Candidate 1 (#1026)
* Version bump and minor fixes * Remove unecessary headers Thanks QtCreator
1 parent 0c3a425 commit e82726b

5 files changed

Lines changed: 8 additions & 7 deletions

File tree

src/aoapplication.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ void AOApplication::destruct_courtroom()
119119

120120
QString AOApplication::get_version_string()
121121
{
122-
return QString::number(RELEASE) + "." + QString::number(MAJOR_VERSION) + "." + QString::number(MINOR_VERSION);
122+
return QString::number(RELEASE) + "." + QString::number(MAJOR_VERSION) + "." + QString::number(MINOR_VERSION) + " RC1";
123123
}
124124

125125
QString AOApplication::find_image(QStringList p_list)

src/aoapplication.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,8 @@ class AOApplication : public QObject
103103
static QString get_version_string();
104104

105105
static const int RELEASE = 2;
106-
static const int MAJOR_VERSION = 10;
107-
static const int MINOR_VERSION = 1;
106+
static const int MAJOR_VERSION = 11;
107+
static const int MINOR_VERSION = 0;
108108

109109
void set_server_list(QVector<ServerInfo> &servers) { server_list = servers; }
110110
QVector<ServerInfo> &get_server_list() { return server_list; }

src/courtroom.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ Courtroom::Courtroom(AOApplication *p_ao_app)
412412
initialize_evidence();
413413

414414
// TODO : Properly handle widget creation order.
415-
// Good enough for 2.10
415+
// Good enough for 2.11
416416
ui_pair_list->raise();
417417

418418
construct_char_select();

src/packet_distribution.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ void AOApplication::server_packet_received(AOPacket packet)
9090
else if (header == "FL")
9191
{
9292
m_serverdata.set_features(content);
93+
w_courtroom->set_widgets();
9394
log_to_demo = false;
9495
}
9596
else if (header == "PN")

src/widgets/playerlistwidget.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ void PlayerListWidget::onCustomContextMenuRequested(const QPoint &pos)
9797
}
9898
});
9999

100-
if (!m_is_authenticated)
100+
if (m_is_authenticated)
101101
{
102102
QAction *kick_player_action = menu->addAction("Kick");
103103
connect(kick_player_action, &QAction::triggered, this, [this, id, name] {
@@ -137,9 +137,9 @@ void PlayerListWidget::removePlayer(int playerId)
137137
void PlayerListWidget::filterPlayerList()
138138
{
139139
int area_id = m_player_map.value(ao_app->client_id).area_id;
140-
for (int i = 0; i < count(); ++i)
140+
for (QListWidgetItem *item : qAsConst(m_item_map))
141141
{
142-
m_item_map[i]->setHidden(m_player_map[i].area_id != area_id);
142+
item->setHidden(m_player_map[item->data(Qt::UserRole).toInt()].area_id != area_id);
143143
}
144144
}
145145

0 commit comments

Comments
 (0)