Git Product home page Git Product logo

electron_screenshot's Introduction

前言

IM 聊天软件需要截图功能。我们找到了一个方法,微信 dll,包装一下生成 exe 文件,我用 Node.js 去调用完成截图。

项目原理:反编译,然后再编译回来。

  1. 第一步先用 Node 执行微信封装的 exe,然后会把截图复制到剪切板
  2. 然后调用浏览把剪切板的内容复制出来
    var screen_window = execFile(__dirname + '/screen/PrintScr.exe')
    screen_window.on('exit', function (code) {
      // 执行成功返回 1,返回 0 没有截图
      if (code) mainWindow.webContents.paste()
    })

截图软件 Git 地址: https://github.com/liangtongzhuo/electron_screenshot

electron_screenshot's People

Contributors

liangtongzhuo avatar

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.