Fixed the problem of double process launch when the application that should be called when pressing a button or closing lid