Exemple #1
0
 public void ApplicationActivated()
 {
     VmAccountData.LogGeneralEvent("Scanner - App Activated");
     lock( this )
     {
         if( ! ShouldControlScannerEnabling() ) return;
         if( _scanModeAtDeactivation != DISABLED )
         {
             _scanHandler = _scanHandlerAtDeactivation;
             _inputSource = _inputSourceAtDeactivation;
             ResumeScanner(_scanModeAtDeactivation);
         }
         _scanModeAtDeactivation = -1;
         _scanHandlerAtDeactivation = null;
     }
 }
Exemple #2
0
        public void ApplicationDeactivated()
        {
            VmAccountData.LogGeneralEvent("Scanner - App De-activated");
            lock( this )
            {
                if( ! ShouldControlScannerEnabling() ) return;
                _scanModeAtDeactivation = _scanMode;
                _scanHandlerAtDeactivation = _scanHandler;
                _inputSourceAtDeactivation = _inputSource;
                if( IsDisabled() ) return;

                SuspendScanner();
            }
        }
Exemple #3
0
        public void SuspendScanner()
        {
            _scanMode = DISABLED;
            _scanHandler = null;

            _SuspendScanner();
        }
Exemple #4
0
        public void ScanAreaGotFocus(Object inputSource, VmScanHandlerIF scanHandler)
        {
            lock( this )
            {

                if( ! ShouldControlScannerEnabling() ) return;
                _inputSource = inputSource;
                _scanHandler = scanHandler;

                ResumeScanner(ENABLE_MODE_SCAN);
            }
        }