예제 #1
0
        /// <summary>
        /// Signs that the device has been attached to the Spectrum virtual machine
        /// </summary>
        public void OnAttachedToVm(ISpectrumVm hostVm)
        {
            HostVm = hostVm;
            var keyboardInfo = HostVm.GetDeviceInfo <IKeyboardDevice>();

            _keyboardProvider = (IKeyboardProvider)keyboardInfo?.Provider;
            _keyboardProvider?.SetKeyStatusHandler(SetStatus);
        }
예제 #2
0
 /// <summary>
 /// Signs that the device has been attached to the Spectrum virtual machine
 /// </summary>
 public void OnAttachedToVm(ISpectrumVm hostVm)
 {
     HostVm = hostVm;
     _keyboardProvider?.SetKeyStatusHandler(SetStatus);
 }