<commit_before>﻿// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.

using System;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.EventSystems;

namespace HoloToolkit.Unity.InputModule
{
    /// <summary>
    /// Xbox Controller support.
    /// <remarks>Only supports one connected device at a time.</remarks>
    /// <remarks>Make sure to enable the <see cref="HumanInterfaceDevice"/> capability before using.</remarks>
    /// </summary>
    public class XboxControllerInputSource : GamePadInputSource
    {
        [Serializable]
        private class MappingEntry
        {
            public XboxControllerMappingTypes Type = 0;
            public string Value = string.Empty;
        }

        private const string XboxController = "Xbox Controller";
        private const string XboxOneForWindows = "Xbox One For Windows";
        private const string XboxBluetoothGamePad = "Xbox Bluetooth Gamepad";
        private const string XboxWirelessController = "Xbox Wireless Controller";

        private readonly Dictionary<uint, XboxControllerData> gamePadInputDatas = new Dictionary<uint, XboxControllerData>(0);

        private uint sourceId;
        private XboxControllerData controllerData;
        private StandaloneInputModule inputModule;
        private string previousHorizontalAxis;
        private string previousVerticalAxis;
        private string previousSubmitButton;
        private string previousCancelButton;
        private bool previousForceActiveState;<commit_msg>updated Mapping entry serialization<commit_after>﻿// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.

using System;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.EventSystems;

namespace HoloToolkit.Unity.InputModule
{
    /// <summary>
    /// Xbox Controller support.
    /// <remarks>Only supports one connected device at a time.</remarks>
    /// <remarks>Make sure to enable the <see cref="HumanInterfaceDevice"/> capability before using.</remarks>
    /// </summary>
    public class XboxControllerInputSource : GamePadInputSource
    {
        [Serializable]
        private class MappingEntry
        {
            public XboxControllerMappingTypes Type = XboxControllerMappingTypes.None;
            public string Value = string.Empty;
        }

        private const string XboxController = "Xbox Controller";
        private const string XboxOneForWindows = "Xbox One For Windows";
        private const string XboxBluetoothGamePad = "Xbox Bluetooth Gamepad";
        private const string XboxWirelessController = "Xbox Wireless Controller";

        private readonly Dictionary<uint, XboxControllerData> gamePadInputDatas = new Dictionary<uint, XboxControllerData>(0);

        private uint sourceId;
        private XboxControllerData controllerData;
        private StandaloneInputModule inputModule;
        private string previousHorizontalAxis;
        private string previousVerticalAxis;
        private string previousSubmitButton;
        private string previousCancelButton;
        private bool previousForceActiveState;
{'fraction_non_alphanumeric': 0.06595744680851064, 'fraction_numerical': 0.000911854103343465, 'mean_word_length': 3.33596837944664, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '535369', 'n_tokens_mistral': 738, 'n_tokens_neox': 731, 'n_words': 264}