general: fix spelling mistakes

This commit is contained in:
Liam 2023-03-11 22:10:38 -05:00
parent d155167ea2
commit 600f325d87
107 changed files with 216 additions and 211 deletions

View file

@ -344,7 +344,7 @@ bool GCAdapter::IsVibrationEnabled([[maybe_unused]] const PadIdentifier& identif
void GCAdapter::UpdateVibrations() {
// Use 8 states to keep the switching between on/off fast enough for
// a human to feel different vibration strenght
// a human to feel different vibration strength
// More states == more rumble strengths == slower update time
constexpr u8 vibration_states = 8;

View file

@ -62,7 +62,7 @@ private:
/// Registers controllers, clears all data and starts the scan thread
void Setup();
/// Actively searchs for new devices
/// Actively searches for new devices
void ScanThread(std::stop_token stop_token);
/// Returns true if device is valid and not registered

View file

@ -24,7 +24,7 @@ constexpr PadIdentifier keyboard_modifier_identifier = {
};
Keyboard::Keyboard(std::string input_engine_) : InputEngine(std::move(input_engine_)) {
// Keyboard is broken into 3 diferent sets:
// Keyboard is broken into 3 different sets:
// key: Unfiltered intended for controllers.
// keyboard_key: Allows only Settings::NativeKeyboard::Keys intended for keyboard emulation.
// keyboard_modifier: Allows only Settings::NativeKeyboard::Modifiers intended for keyboard

View file

@ -142,7 +142,7 @@ void Mouse::Move(int x, int y, int center_x, int center_y) {
return;
}
// Make slow movements at least 3 units on lenght
// Make slow movements at least 3 units on length
if (move_distance < 3.0f) {
// Normalize value
mouse_change /= move_distance;
@ -154,7 +154,7 @@ void Mouse::Move(int x, int y, int center_x, int center_y) {
const auto last_move_distance = last_mouse_change.Length();
// Make fast movements clamp to 8 units on lenght
// Make fast movements clamp to 8 units on length
if (last_move_distance > 8.0f) {
// Normalize value
last_mouse_change /= last_move_distance;

View file

@ -748,7 +748,7 @@ ButtonMapping SDLDriver::GetButtonMappingForDevice(const Common::ParamPackage& p
// This list is missing ZL/ZR since those are not considered buttons in SDL GameController.
// We will add those afterwards
// This list also excludes Screenshot since theres not really a mapping for that
// This list also excludes Screenshot since there's not really a mapping for that
ButtonBindings switch_to_sdl_button;
if (SDL_GameControllerGetType(controller) == SDL_CONTROLLER_TYPE_NINTENDO_SWITCH_PRO) {
@ -1007,7 +1007,7 @@ MotionMapping SDLDriver::GetMotionMappingForDevice(const Common::ParamPackage& p
Common::Input::ButtonNames SDLDriver::GetUIName(const Common::ParamPackage& params) const {
if (params.Has("button")) {
// TODO(German77): Find how to substitue the values for real button names
// TODO(German77): Find how to substitute the values for real button names
return Common::Input::ButtonNames::Value;
}
if (params.Has("hat")) {

View file

@ -57,7 +57,7 @@ Common::Input::NfcState VirtualAmiibo::WriteNfcData(
}
if (!nfc_file.Write(data)) {
LOG_ERROR(Service_NFP, "Error writting to file");
LOG_ERROR(Service_NFP, "Error writing to file");
return Common::Input::NfcState::WriteFailed;
}

View file

@ -164,8 +164,8 @@ void JoyconDriver::InputThread(std::stop_token stop_token) {
void JoyconDriver::OnNewData(std::span<u8> buffer) {
const auto report_mode = static_cast<ReportMode>(buffer[0]);
// Packages can be a litte bit inconsistent. Average the delta time to provide a smoother motion
// experience
// Packages can be a little bit inconsistent. Average the delta time to provide a smoother
// motion experience
switch (report_mode) {
case ReportMode::STANDARD_FULL_60HZ:
case ReportMode::NFC_IR_MODE_60HZ:

View file

@ -73,7 +73,7 @@ private:
/// Main thread, actively request new data from the handle
void InputThread(std::stop_token stop_token);
/// Called everytime a valid package arrives
/// Called every time a valid package arrives
void OnNewData(std::span<u8> buffer);
/// Updates device configuration to enable or disable features
@ -110,7 +110,7 @@ private:
bool amiibo_detected{};
bool is_ring_disabled_by_irs{};
// Harware configuration
// Hardware configuration
u8 leds{};
ReportMode mode{};
bool passive_enabled{}; // Low power mode, Ideal for multiple controllers at the same time

View file

@ -68,7 +68,7 @@ public:
}
/**
* Waits for incoming data of the joycon device that matchs the subcommand
* Waits for incoming data of the joycon device that matches the subcommand
* @param sub_command type of data to be returned
* @returns a buffer containing the response
*/
@ -137,7 +137,7 @@ public:
DriverResult EnableMCU(bool enable);
/**
* Configures the MCU to the correspoinding mode
* Configures the MCU to the corresponding mode
* @param MCUConfig configuration
*/
DriverResult ConfigureMCU(const MCUConfig& config);

View file

@ -25,7 +25,7 @@ namespace Response {
/**
* Returns Type if the packet is valid, else none
*
* Note: Modifies the buffer to zero out the crc (since thats the easiest way to check without
* Note: Modifies the buffer to zero out the crc (since that's the easiest way to check without
* copying the buffer)
*/
std::optional<Type> Validate(u8* data, std::size_t size) {

View file

@ -132,7 +132,7 @@ public:
/// Retrieves the motion mappings for the given device.
[[nodiscard]] MotionMapping GetMotionMappingForDevice(const Common::ParamPackage& device) const;
/// Returns an enum contaning the name to be displayed from the input engine.
/// Returns an enum containing the name to be displayed from the input engine.
[[nodiscard]] Common::Input::ButtonNames GetButtonName(
const Common::ParamPackage& params) const;