Skip to content
Permalink
Browse files

Rename all instances of "CemuhookUDPServer"/"UDPServer" to "DualShock…

…UDPClient"/"DSUClient".
  • Loading branch information...
rlnilsen committed Oct 26, 2019
1 parent 332cad2 commit da1f153b47a3f3f4eb9b976670bfddf68108bae9
Showing with 85 additions and 87 deletions.
  1. +1 −1 Source/Core/Common/CommonPaths.h
  2. +1 −1 Source/Core/Common/Config/Config.cpp
  3. +1 −1 Source/Core/Common/Config/Enums.h
  4. +2 −2 Source/Core/Common/FileUtil.cpp
  5. +1 −1 Source/Core/Common/FileUtil.h
  6. +1 −1 Source/Core/Core/ConfigLoaders/BaseConfigLoader.cpp
  7. +1 −1 Source/Core/Core/ConfigLoaders/IsSettingSaveable.cpp
  8. +2 −2 Source/Core/DolphinQt/CMakeLists.txt
  9. +5 −5 Source/Core/DolphinQt/Config/ControllerInterface/ControllerInterfaceWindow.cpp
  10. +4 −4 Source/Core/DolphinQt/Config/ControllerInterface/ControllerInterfaceWindow.h
  11. +13 −13 ...DolphinQt/Config/ControllerInterface/{CemuHookUDPServerWidget.cpp → DualShockUDPClientWidget.cpp}
  12. +2 −2 ...ore/DolphinQt/Config/ControllerInterface/{CemuHookUDPServerWidget.h → DualShockUDPClientWidget.h}
  13. +3 −3 Source/Core/DolphinQt/DolphinQt.vcxproj
  14. +3 −3 Source/Core/InputCommon/CMakeLists.txt
  15. +8 −8 Source/Core/InputCommon/ControllerInterface/ControllerInterface.cpp
  16. +1 −1 Source/Core/InputCommon/ControllerInterface/ControllerInterface.h
  17. +16 −16 ...erInterface/{CemuHookUDPServer/CemuHookUDPServer.cpp → DualShockUDPClient/DualShockUDPClient.cpp}
  18. +2 −2 ...rollerInterface/{CemuHookUDPServer/CemuHookUDPServer.h → DualShockUDPClient/DualShockUDPClient.h}
  19. +4 −4 ...erInterface/{CemuHookUDPServer/CemuHookUDPServerProto.h → DualShockUDPClient/DualShockUDPProto.h}
  20. +3 −3 Source/Core/InputCommon/InputCommon.vcxproj
  21. +11 −13 Source/Core/InputCommon/InputCommon.vcxproj.filters
@@ -85,7 +85,7 @@
#define GFX_CONFIG "GFX.ini"
#define DEBUGGER_CONFIG "Debugger.ini"
#define LOGGER_CONFIG "Logger.ini"
#define CEMUHOOKUDPSERVER_CONFIG "UDPServer.ini"
#define DUALSHOCKUDPCLIENT_CONFIG "DSUClient.ini"

// Files in the directory returned by GetUserPath(D_LOGS_IDX)
#define MAIN_LOG "dolphin.log"
@@ -141,7 +141,7 @@ static const std::map<System, std::string> system_to_name = {
{System::Logger, "Logger"},
{System::Debugger, "Debugger"},
{System::SYSCONF, "SYSCONF"},
{System::CemuHookUdpServer, "CemuHookUdpServer"}};
{System::DualShockUDPClient, "DualShockUDPClient"}};

const std::string& GetSystemName(System system)
{
@@ -30,7 +30,7 @@ enum class System
GFX,
Logger,
Debugger,
CemuHookUdpServer,
DualShockUDPClient,
};

constexpr std::array<LayerType, 7> SEARCH_ORDER{{
@@ -794,8 +794,8 @@ static void RebuildUserDirectories(unsigned int dir_index)
s_user_paths[F_GFXCONFIG_IDX] = s_user_paths[D_CONFIG_IDX] + GFX_CONFIG;
s_user_paths[F_DEBUGGERCONFIG_IDX] = s_user_paths[D_CONFIG_IDX] + DEBUGGER_CONFIG;
s_user_paths[F_LOGGERCONFIG_IDX] = s_user_paths[D_CONFIG_IDX] + LOGGER_CONFIG;
s_user_paths[F_CEMUHOOKUDPSERVERCONFIG_IDX] =
s_user_paths[D_CONFIG_IDX] + CEMUHOOKUDPSERVER_CONFIG;
s_user_paths[F_DUALSHOCKUDPCLIENTCONFIG_IDX] =
s_user_paths[D_CONFIG_IDX] + DUALSHOCKUDPCLIENT_CONFIG;
s_user_paths[F_MAINLOG_IDX] = s_user_paths[D_LOGS_IDX] + MAIN_LOG;
s_user_paths[F_MEM1DUMP_IDX] = s_user_paths[D_DUMP_IDX] + MEM1_DUMP;
s_user_paths[F_MEM2DUMP_IDX] = s_user_paths[D_DUMP_IDX] + MEM2_DUMP;
@@ -70,7 +70,7 @@ enum
F_MEMORYWATCHERLOCATIONS_IDX,
F_MEMORYWATCHERSOCKET_IDX,
F_WIISDCARD_IDX,
F_CEMUHOOKUDPSERVERCONFIG_IDX,
F_DUALSHOCKUDPCLIENTCONFIG_IDX,
NUM_PATH_INDICES
};

@@ -89,7 +89,7 @@ const std::map<Config::System, int> system_to_ini = {
{Config::System::GFX, F_GFXCONFIG_IDX},
{Config::System::Logger, F_LOGGERCONFIG_IDX},
{Config::System::Debugger, F_DEBUGGERCONFIG_IDX},
{Config::System::CemuHookUdpServer, F_CEMUHOOKUDPSERVERCONFIG_IDX},
{Config::System::DualShockUDPClient, F_DUALSHOCKUDPCLIENTCONFIG_IDX},
};

// INI layer configuration loader
@@ -16,7 +16,7 @@ namespace ConfigLoaders
{
bool IsSettingSaveable(const Config::ConfigLocation& config_location)
{
if (config_location.system == Config::System::CemuHookUdpServer)
if (config_location.system == Config::System::DualShockUDPClient)
return true;

if (config_location.system == Config::System::Logger)
@@ -51,8 +51,8 @@ add_executable(dolphin-emu
Config/CheatCodeEditor.h
Config/CheatWarningWidget.cpp
Config/CheatWarningWidget.h
Config/ControllerInterface/CemuHookUDPServerWidget.cpp
Config/ControllerInterface/CemuHookUDPServerWidget.h
Config/ControllerInterface/DualShockUDPClientWidget.cpp
Config/ControllerInterface/DualShockUDPClientWidget.h
Config/ControllerInterface/ControllerInterfaceWindow.cpp
Config/ControllerInterface/ControllerInterfaceWindow.h
Config/ControllersWindow.cpp
@@ -9,8 +9,8 @@
#include <QTabWidget>
#include <QVBoxLayout>

#if defined(CIFACE_USE_CEMUHOOKUDPSERVER)
#include "DolphinQt/Config/ControllerInterface/CemuHookUDPServerWidget.h"
#if defined(CIFACE_USE_DUALSHOCKUDPCLIENT)
#include "DolphinQt/Config/ControllerInterface/DualShockUDPClientWidget.h"
#endif

ControllerInterfaceWindow::ControllerInterfaceWindow(QWidget* parent) : QDialog(parent)
@@ -27,9 +27,9 @@ void ControllerInterfaceWindow::CreateMainLayout()
connect(m_button_box, &QDialogButtonBox::rejected, this, &QDialog::reject);

m_tab_widget = new QTabWidget();
#if defined(CIFACE_USE_CEMUHOOKUDPSERVER)
m_udpserver_widget = new CemuHookUDPServerWidget();
m_tab_widget->addTab(m_udpserver_widget, tr("UDPServer")); // TODO: use GetWrappedWidget()?
#if defined(CIFACE_USE_DUALSHOCKUDPCLIENT)
m_dsuclient_widget = new DualShockUDPClientWidget();
m_tab_widget->addTab(m_dsuclient_widget, tr("DSU Client")); // TODO: use GetWrappedWidget()?
#endif

auto* main_layout = new QVBoxLayout();
@@ -8,8 +8,8 @@

#include "InputCommon/ControllerInterface/ControllerInterface.h"

#if defined(CIFACE_USE_CEMUHOOKUDPSERVER)
class CemuHookUDPServerWidget;
#if defined(CIFACE_USE_DUALSHOCKUDPCLIENT)
class DualShockUDPClientWidget;
#endif
class QTabWidget;
class QDialogButtonBox;
@@ -26,7 +26,7 @@ class ControllerInterfaceWindow final : public QDialog
QTabWidget* m_tab_widget;
QDialogButtonBox* m_button_box;

#if defined(CIFACE_USE_CEMUHOOKUDPSERVER)
CemuHookUDPServerWidget* m_udpserver_widget;
#if defined(CIFACE_USE_DUALSHOCKUDPCLIENT)
DualShockUDPClientWidget* m_dsuclient_widget;
#endif
};
@@ -2,7 +2,7 @@
// Licensed under GPLv2+
// Refer to the license.txt file included.

#include "DolphinQt/Config/ControllerInterface/CemuHookUDPServerWidget.h"
#include "DolphinQt/Config/ControllerInterface/DualShockUDPClientWidget.h"

#include <QCheckBox>
#include <QGridLayout>
@@ -12,33 +12,33 @@
#include <QSpinBox>

#include "Common/Config/Config.h"
#include "InputCommon/ControllerInterface/CemuHookUDPServer/CemuHookUDPServer.h"
#include "InputCommon/ControllerInterface/DualShockUDPClient/DualShockUDPClient.h"

CemuHookUDPServerWidget::CemuHookUDPServerWidget()
DualShockUDPClientWidget::DualShockUDPClientWidget()
{
CreateWidgets();
ConnectWidgets();
}

void CemuHookUDPServerWidget::CreateWidgets()
void DualShockUDPClientWidget::CreateWidgets()
{
auto* main_layout = new QGridLayout;

m_server_enabled = new QCheckBox(tr("Enable"));
m_server_enabled->setChecked(Config::Get(ciface::CemuHookUDPServer::Settings::SERVER_ENABLED));
m_server_enabled->setChecked(Config::Get(ciface::DualShockUDPClient::Settings::SERVER_ENABLED));

m_server_address = new QLineEdit(
QString::fromStdString(Config::Get(ciface::CemuHookUDPServer::Settings::SERVER_ADDRESS)));
QString::fromStdString(Config::Get(ciface::DualShockUDPClient::Settings::SERVER_ADDRESS)));

m_server_port = new QSpinBox();
m_server_port->setMaximum(65535);
m_server_port->setValue(Config::Get(ciface::CemuHookUDPServer::Settings::SERVER_PORT));
m_server_port->setValue(Config::Get(ciface::DualShockUDPClient::Settings::SERVER_PORT));

auto* description =
new QLabel(tr("UDPServer protocol enables the use of input and motion data from compatible "
new QLabel(tr("DSU protocol enables the use of input and motion data from compatible "
"sources, like PlayStation, Nintendo Switch and Steam controllers.<br><br>"
"For setup instructions, "
"<a href=\"https://wiki.dolphin-emu.org/index.php?title=UDPServer\">"
"<a href=\"https://wiki.dolphin-emu.org/index.php?title=DSU_Client\">"
"refer to this page</a>."));
description->setTextFormat(Qt::RichText);
description->setWordWrap(true);
@@ -55,21 +55,21 @@ void CemuHookUDPServerWidget::CreateWidgets()
setLayout(main_layout);
}

void CemuHookUDPServerWidget::ConnectWidgets()
void DualShockUDPClientWidget::ConnectWidgets()
{
connect(m_server_enabled, &QCheckBox::toggled, this, [this] {
Config::SetBaseOrCurrent(ciface::CemuHookUDPServer::Settings::SERVER_ENABLED,
Config::SetBaseOrCurrent(ciface::DualShockUDPClient::Settings::SERVER_ENABLED,
m_server_enabled->isChecked());
});

connect(m_server_address, &QLineEdit::editingFinished, this, [this] {
Config::SetBaseOrCurrent(ciface::CemuHookUDPServer::Settings::SERVER_ADDRESS,
Config::SetBaseOrCurrent(ciface::DualShockUDPClient::Settings::SERVER_ADDRESS,
m_server_address->text().toStdString());
});

connect(m_server_port, static_cast<void (QSpinBox::*)(int)>(&QSpinBox::valueChanged), this,
[this] {
Config::SetBaseOrCurrent(ciface::CemuHookUDPServer::Settings::SERVER_PORT,
Config::SetBaseOrCurrent(ciface::DualShockUDPClient::Settings::SERVER_PORT,
static_cast<u16>(m_server_port->value()));
});
}
@@ -10,11 +10,11 @@ class QCheckBox;
class QLineEdit;
class QSpinBox;

class CemuHookUDPServerWidget final : public QWidget
class DualShockUDPClientWidget final : public QWidget
{
Q_OBJECT
public:
explicit CemuHookUDPServerWidget();
explicit DualShockUDPClientWidget();

private:
void CreateWidgets();
@@ -106,7 +106,7 @@
<QtMoc Include="Config\Graphics\HacksWidget.h" />
<QtMoc Include="Config\Graphics\PostProcessingConfigWindow.h" />
<QtMoc Include="Config\Graphics\SoftwareRendererWidget.h" />
<QtMoc Include="Config\ControllerInterface\CemuHookUDPServerWidget.h" />
<QtMoc Include="Config\ControllerInterface\DualShockUDPClientWidget.h" />
<QtMoc Include="Config\ControllerInterface\ControllerInterfaceWindow.h" />
<QtMoc Include="Config\InfoWidget.h" />
<QtMoc Include="Config\PatchesWidget.h" />
@@ -189,7 +189,7 @@
<ClCompile Include="$(QtMocOutPrefix)ChunkedProgressDialog.cpp" />
<ClCompile Include="$(QtMocOutPrefix)CodeViewWidget.cpp" />
<ClCompile Include="$(QtMocOutPrefix)CodeWidget.cpp" />
<ClCompile Include="$(QtMocOutPrefix)CemuHookUDPServerWidget.cpp" />
<ClCompile Include="$(QtMocOutPrefix)DualShockUDPClientWidget.cpp" />
<ClCompile Include="$(QtMocOutPrefix)ControllerInterfaceWindow.cpp" />
<ClCompile Include="$(QtMocOutPrefix)ControllersWindow.cpp" />
<ClCompile Include="$(QtMocOutPrefix)DiscordHandler.cpp" />
@@ -295,7 +295,7 @@
<ClCompile Include="Config\CheatCodeEditor.cpp" />
<ClCompile Include="Config\ARCodeWidget.cpp" />
<ClCompile Include="Config\CheatWarningWidget.cpp" />
<ClCompile Include="Config\ControllerInterface\CemuHookUDPServerWidget.cpp" />
<ClCompile Include="Config\ControllerInterface\DualShockUDPClientWidget.cpp" />
<ClCompile Include="Config\ControllerInterface\ControllerInterfaceWindow.cpp" />
<ClCompile Include="Config\ControllersWindow.cpp" />
<ClCompile Include="Config\FilesystemWidget.cpp" />
@@ -43,9 +43,9 @@ add_library(inputcommon
ControllerEmu/ControlGroup/Triggers.h
ControllerEmu/Setting/NumericSetting.cpp
ControllerEmu/Setting/NumericSetting.h
ControllerInterface/CemuHookUDPServer/CemuHookUDPServer.cpp
ControllerInterface/CemuHookUDPServer/CemuHookUDPServer.h
ControllerInterface/CemuHookUDPServer/CemuHookUDPServerProto.h
ControllerInterface/DualShockUDPClient/DualShockUDPClient.cpp
ControllerInterface/DualShockUDPClient/DualShockUDPClient.h
ControllerInterface/DualShockUDPClient/DualShockUDPProto.h
ControllerInterface/ControllerInterface.cpp
ControllerInterface/ControllerInterface.h
ControllerInterface/Device.cpp
@@ -30,8 +30,8 @@
#ifdef CIFACE_USE_PIPES
#include "InputCommon/ControllerInterface/Pipes/Pipes.h"
#endif
#ifdef CIFACE_USE_CEMUHOOKUDPSERVER
#include "InputCommon/ControllerInterface/CemuHookUDPServer/CemuHookUDPServer.h"
#ifdef CIFACE_USE_DUALSHOCKUDPCLIENT
#include "InputCommon/ControllerInterface/DualShockUDPClient/DualShockUDPClient.h"
#endif

ControllerInterface g_controller_interface;
@@ -71,8 +71,8 @@ void ControllerInterface::Initialize(const WindowSystemInfo& wsi)
#ifdef CIFACE_USE_PIPES
// nothing needed
#endif
#ifdef CIFACE_USE_CEMUHOOKUDPSERVER
ciface::CemuHookUDPServer::Init();
#ifdef CIFACE_USE_DUALSHOCKUDPCLIENT
ciface::DualShockUDPClient::Init();
#endif

RefreshDevices();
@@ -128,8 +128,8 @@ void ControllerInterface::RefreshDevices()
#ifdef CIFACE_USE_PIPES
ciface::Pipes::PopulateDevices();
#endif
#ifdef CIFACE_USE_CEMUHOOKUDPSERVER
ciface::CemuHookUDPServer::PopulateDevices();
#ifdef CIFACE_USE_DUALSHOCKUDPCLIENT
ciface::DualShockUDPClient::PopulateDevices();
#endif

m_is_populating_devices = false;
@@ -181,8 +181,8 @@ void ControllerInterface::Shutdown()
#ifdef CIFACE_USE_EVDEV
ciface::evdev::Shutdown();
#endif
#ifdef CIFACE_USE_CEMUHOOKUDPSERVER
ciface::CemuHookUDPServer::DeInit();
#ifdef CIFACE_USE_DUALSHOCKUDPCLIENT
ciface::DualShockUDPClient::DeInit();
#endif
}

@@ -29,7 +29,7 @@
#if defined(USE_PIPES)
#define CIFACE_USE_PIPES
#endif
#define CIFACE_USE_CEMUHOOKUDPSERVER
#define CIFACE_USE_DUALSHOCKUDPCLIENT

//
// ControllerInterface

0 comments on commit da1f153

Please sign in to comment.
You can’t perform that action at this time.