MCPcopy Create free account
hub / github.com/RGAA-Software/GoDesk / RpSyncPanelInfo

Method RpSyncPanelInfo

src/render_panel/network/ws_panel_server.cpp:453–477  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

451 }
452
453 void WsPanelServer::RpSyncPanelInfo() {
454 tcrp::RpMessage m;
455 m.set_type(tcrp::RpMessageType::kSyncPanelInfo);
456 auto sub = m.mutable_sync_panel_info();
457 sub->set_device_id(settings_->GetDeviceId());
458 sub->set_device_random_pwd(settings_->GetDeviceRandomPwd());
459 sub->set_device_safety_pwd(settings_->GetDeviceSecurityPwd());
460 sub->set_relay_host(settings_->GetRelayServerHost());
461 sub->set_relay_port(std::to_string(settings_->GetRelayServerPort()));
462 sub->set_can_be_operated(settings_->IsBeingOperatedEnabled());
463 sub->set_relay_enabled(settings_->IsRelayEnabled());
464 sub->set_language((int)tcTrMgr()->GetSelectedLanguage());
465 sub->set_file_transfer_enabled(settings_->IsFileTransferEnabled());
466 sub->set_audio_enabled(settings_->IsCaptureAudioEnabled());
467 sub->set_appkey(grApp->GetAppkey());
468 sub->set_max_transmit_speed(this->max_transmit_speed_);
469 sub->set_max_receive_speed(this->max_receive_speed_);
470 if (auto pc = grApp->GetCompanion(); pc && pc->GetAuth()) {
471 sub->set_role(static_cast<int>(pc->GetAuth()->role_));
472 }
473 else {
474 sub->set_role(1);
475 }
476 PostRendererMessage(tc::RpProtoAsData(&m));
477 }
478
479 void WsPanelServer::ParseFtBinaryMessage(uint64_t socket_fd, std::string_view msg) {
480 if (ft_sessions_.HasKey(socket_fd)) {

Callers 2

WsPanelServerMethod · 0.95
AddWebsocketRouterMethod · 0.95

Calls 12

to_stringFunction · 0.85
GetDeviceRandomPwdMethod · 0.80
GetDeviceSecurityPwdMethod · 0.80
GetRelayServerHostMethod · 0.80
GetRelayServerPortMethod · 0.80
IsRelayEnabledMethod · 0.80
IsFileTransferEnabledMethod · 0.80
IsCaptureAudioEnabledMethod · 0.80
GetAppkeyMethod · 0.80
GetCompanionMethod · 0.80
GetDeviceIdMethod · 0.45

Tested by

no test coverage detected