mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-02-12 23:48:58 +01:00
![Lioncash](/assets/img/avatar_default.png)
ControllerEmu, the class, is essentially acting like a namespace for ControlGroup. This makes it impossible to forward declare any of the internals. It also globs a bunch of classes together which is kind of a pain to manage. This splits ControlGroup and the classes it contains into their own source files and situates them all within a namespace, which gets them out of global scope. Since this allows forward declarations for the once-internal classes, it now requires significantly less files to be rebuilt if anything is changed in the ControllerEmu portion of code. It does not split out the settings classes yet, however, as it would be preferable to make a settings base class that all settings derive from, but this would be a functional change -- this commit only intends to move around existing code. Extracting the settings class will be done in another commit.
33 lines
608 B
C++
33 lines
608 B
C++
// Copyright 2008 Dolphin Emulator Project
|
|
// Licensed under GPLv2+
|
|
// Refer to the license.txt file included.
|
|
|
|
#pragma once
|
|
|
|
#include "Common/CommonTypes.h"
|
|
#include "InputCommon/ControllerInterface/Device.h"
|
|
|
|
class InputConfig;
|
|
enum class PadGroup;
|
|
struct GCPadStatus;
|
|
|
|
namespace ControllerEmu
|
|
{
|
|
class ControlGroup;
|
|
}
|
|
|
|
namespace Pad
|
|
{
|
|
void Shutdown();
|
|
void Initialize();
|
|
void LoadConfig();
|
|
|
|
InputConfig* GetConfig();
|
|
|
|
GCPadStatus GetStatus(int pad_num);
|
|
ControllerEmu::ControlGroup* GetGroup(int pad_num, PadGroup group);
|
|
void Rumble(int pad_num, ControlState strength);
|
|
|
|
bool GetMicButton(int pad_num);
|
|
}
|