GithubHelp home page GithubHelp logo

killmsgbox's Introduction

KillMsgBox

A utility to block annoying popup windows

How does it work?

There are two types of popup ads, one is to create a form and the other is to map directly. Therefore, we have two ways to close the popup. For the first type of popup window, we set a timer to traverse the top level window at regular intervals and get the window handle to get the window position information. We judge the position information displayed by the window and determine if it appears on the edge of the screen. If the conditions are met, send WM_CLOSE to close the window. To reduce the chance of accidental death, we obtain the path of the window process according to the identifier and determine if it is a system process according to the path. If it is a system process, it will not be closed; otherwise, determine the status of the window display at this time, if so. The display status is closed. For the second situation of pasting images, we configure global message bindings to inject DLL files to achieve API bindings. We connect the three API functions BitBlt, StretchBlt and TransparentBlt to get the drawing position and HDC. According to the content of the HDC device, we can use the WindowFromDC function to obtain the window identifier corresponding to the HDC. Depending on the identifier, we can get the size of the client area of ​​the window. Then determine if the drawing position meets the condition of being located on the edge of the customer area. The width and height of the drawing are set to 0 to achieve the effect of not drawing the image.

killmsgbox's People

Watchers

Adolfo Lorenzo Cristóbal Pérez avatar

Forkers

15831944

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.