Example #1
0
        public void LoadBindings()
        {
            var container = BindingsContainer.Deserialize(GetBindingsFilePath());

            MappingsDataBinding = container.Mappings;
            MacrosDataBinding   = container.Macros;
        }
Example #2
0
        public static void Serialize(string path, BindingsContainer container)
        {
            XmlSerializer serializer = new XmlSerializer(typeof(BindingsContainer));

            using (TextWriter writer = new StreamWriter(path))
            {
                serializer.Serialize(writer, container);
            }
        }
Example #3
0
        public void SaveBindings()
        {
            var container = new BindingsContainer();

            container.Mappings = MappingsDataBinding;
            container.Macros   = MacrosDataBinding;

            BindingsContainer.Serialize(GetBindingsFilePath(), container);
        }
Example #4
0
        public static BindingsContainer Deserialize(string path)
        {
            XmlSerializer deserializer = new XmlSerializer(typeof(BindingsContainer));

            using (TextReader reader = new StreamReader(path))
            {
                object            obj       = deserializer.Deserialize(reader);
                BindingsContainer container = obj as BindingsContainer;
                return(container);
            }
        }
Example #5
0
        public void LoadBindings()
        {
            var container = BindingsContainer.Deserialize(GetBindingsFilePath());

            MappingsDataBinding = container.Mappings;
            MacrosDataBinding   = container.Macros;

            EnableMouseInput    = container.EnableMouseInput;
            MouseSensitivity    = container.MouseSensitivity;
            FrameRefresh        = container.FrameRefresh;
            Borders             = container.Borders;
            MouseMovementAnalog = container.MouseMovementAnalog;
            MouseInvertXAxis    = container.MouseInvertXAxis;
            MouseInvertYAxis    = container.MouseInvertYAxis;
            LeftMouseMapping    = container.LeftMouseMapping;
            RightMouseMapping   = container.RightMouseMapping;
            MiddleMouseMapping  = container.MiddleMouseMapping;
        }
Example #6
0
        public void LoadBindings()
        {
            var container = BindingsContainer.Deserialize(GetBindingsFilePath());

            MappingsDataBinding = container.Mappings;
            MacrosDataBinding   = container.Macros;

            EnableMouseInput    = container.EnableMouseInput;
            MouseSensitivity    = container.MouseSensitivity;
            MouseDecayRate      = container.MouseDecayRate;
            MouseDecayThreshold = container.MouseDecayThreshold;
            MouseAnalogDeadzone = container.MouseAnalogDeadzone;
            MouseMakeupSpeed    = container.MouseMakeupSpeed;
            MouseMovementAnalog = container.MouseMovementAnalog;
            MouseInvertXAxis    = container.MouseInvertXAxis;
            MouseInvertYAxis    = container.MouseInvertYAxis;
            LeftMouseMapping    = container.LeftMouseMapping;
            RightMouseMapping   = container.RightMouseMapping;
        }
Example #7
0
        public void SaveBindings()
        {
            var container = new BindingsContainer
            {
                Mappings            = MappingsDataBinding,
                Macros              = MacrosDataBinding,
                EnableMouseInput    = EnableMouseInput,
                MouseSensitivity    = MouseSensitivity,
                FrameRefresh        = FrameRefresh,
                Borders             = Borders,
                MouseMovementAnalog = MouseMovementAnalog,
                MouseInvertXAxis    = MouseInvertXAxis,
                MouseInvertYAxis    = MouseInvertYAxis,
                LeftMouseMapping    = LeftMouseMapping,
                RightMouseMapping   = RightMouseMapping,
                MiddleMouseMapping  = MiddleMouseMapping
            };


            BindingsContainer.Serialize(GetBindingsFilePath(), container);
        }
Example #8
0
        public void SaveBindings()
        {
            var container = new BindingsContainer
            {
                Mappings            = MappingsDataBinding,
                Macros              = MacrosDataBinding,
                EnableMouseInput    = EnableMouseInput,
                MouseSensitivity    = MouseSensitivity,
                MouseDecayRate      = MouseDecayRate,
                MouseDecayThreshold = MouseDecayThreshold,
                MouseAnalogDeadzone = MouseAnalogDeadzone,
                MouseMakeupSpeed    = MouseMakeupSpeed,
                MouseMovementAnalog = MouseMovementAnalog,
                MouseInvertXAxis    = MouseInvertXAxis,
                MouseInvertYAxis    = MouseInvertYAxis,
                LeftMouseMapping    = LeftMouseMapping,
                RightMouseMapping   = RightMouseMapping
            };


            BindingsContainer.Serialize(GetBindingsFilePath(), container);
        }