decreased number of events handled using global lock variable and skipping events without a file associated to the view