Skip to content

Commit

Permalink
fix cdc-x invis auto-connect, remove dj buttons
Browse files Browse the repository at this point in the history
dj-ing isn't used by current cdc-x users, and audio streaming via chat server is removed at the moment
  • Loading branch information
blindchimp committed Aug 20, 2018
1 parent 2099409 commit c5e764b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
1 change: 1 addition & 0 deletions cdcx/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ DwOString Current_server_id;
int Last_server = -1;
DwOString Last_server_id;
DwOString Last_selected_id;
int Last_selected_idx = -1;
extern int AvoidCamera;
int AvoidSSL;
int Askup;
Expand Down
7 changes: 5 additions & 2 deletions cdcx/mainwin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ extern DwOString Current_server_id;
extern int Last_server;
extern DwOString Last_server_id;
extern DwOString Last_selected_id;
extern int Last_selected_idx;
extern int Askup;
static int Ask_lobby_pw;
static DwOString Ask_lobby_pw_id;
Expand Down Expand Up @@ -574,6 +575,7 @@ set_current_server(int i)
Current_server = i;
Current_server_id = "";
Last_selected_id = "";
Last_selected_idx = i;
setting_put("server", i);
setting_put("server_id", DwOString(""));
settings_save();
Expand Down Expand Up @@ -659,6 +661,7 @@ set_current_server(const DwOString& id)
Current_server = -1;
Current_server_id = id;
Last_selected_id = id;
Last_selected_idx = -1;
// by avoiding setting the server to -1, we can make sure
// we log into a system server
//setting_put("server", -1);
Expand Down Expand Up @@ -4323,8 +4326,8 @@ void mainwinform::on_actionRemove_lobby_triggered()

void mainwinform::on_actionMake_me_invisible_triggered(bool checked)
{
int tmp1 = Current_server;
DwOString tmp2 = Current_server_id;
int tmp1 = Last_selected_idx;
DwOString tmp2 = Last_selected_id;
dwyco_set_invisible_state(checked);
// chat server will disconnect synchronously at this point, so we need to reissue a login

Expand Down
3 changes: 3 additions & 0 deletions cdcx/simple_public.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,9 @@ simple_public::simple_public(QWidget *parent) :

ui->dj->setDefaultAction(ui->actionDj);
ui->mute->setDefaultAction(ui->actionMute);
ui->dj->setVisible(0);
ui->mute->setVisible(0);

ui->send_snapchat->setDefaultAction(ui->actionSend_snapchat);

if(!HasAudioInput)
Expand Down

0 comments on commit c5e764b

Please sign in to comment.