aboutsummaryrefslogtreecommitdiff
path: root/lobby.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lobby.cpp')
-rw-r--r--lobby.cpp21
1 files changed, 16 insertions, 5 deletions
diff --git a/lobby.cpp b/lobby.cpp
index 0a1a88e..a0b37a8 100644
--- a/lobby.cpp
+++ b/lobby.cpp
@@ -28,6 +28,10 @@ Lobby::Lobby(AOApplication *p_ao_app) : QMainWindow()
ui_chatbox = new QPlainTextEdit(this);
ui_chatname = new QLineEdit(this);
ui_chatmessage = new QLineEdit(this);
+ ui_loading_background = new AOImage(this, ao_app);
+ ui_loading_label = new QLabel(ui_loading_background);
+ ui_progress_bar = new QProgressBar(ui_loading_background);
+ ui_cancel = new AOButton(ui_loading_background, ao_app);
connect(ui_public_servers, SIGNAL(clicked()), this, SLOT(on_public_servers_clicked()));
connect(ui_favorites, SIGNAL(clicked()), this, SLOT(on_favorites_clicked()));
@@ -97,6 +101,16 @@ void Lobby::set_widgets()
ui_chatmessage->setStyleSheet("background-color: rgba(0, 0, 0, 0);"
"selection-background-color: rgba(0, 0, 0, 0);");
+ ui_loading_background->set_image("loadingbackground.png");
+ ui_loading_background->resize(m_lobby_width, m_lobby_height);
+
+ set_size_and_pos(ui_loading_label, "loading_label");
+ set_size_and_pos(ui_progress_bar, "progress_bar");
+ set_size_and_pos(ui_cancel, "cancel");
+ ui_cancel->setText("Cancel");
+
+ ui_loading_background->hide();
+
}
void Lobby::set_size_and_pos(QWidget *p_widget, QString p_identifier)
@@ -185,11 +199,8 @@ void Lobby::on_connect_released()
{
ui_connect->set_image("connect.png");
- //D3BUG
- //AOPacket *f_packet = new AOPacket("askchaa#%");
- ao_app->construct_courtroom();
- //ao_app->send_server_packet(f_packet);
- //D3BUG END
+ AOPacket *f_packet = new AOPacket("askchaa#%");
+ ao_app->send_server_packet(f_packet);
}
void Lobby::on_about_clicked()