mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-08 12:18:50 +02:00
18 lines
392 B
C
18 lines
392 B
C
|
|
#pragma once
|
||
|
|
|
||
|
|
#include <functional>
|
||
|
|
|
||
|
|
class MouseButtonsHook
|
||
|
|
{
|
||
|
|
public:
|
||
|
|
MouseButtonsHook(std::function<void()>, std::function<void()>);
|
||
|
|
void enable();
|
||
|
|
void disable();
|
||
|
|
|
||
|
|
private:
|
||
|
|
static HHOOK hHook;
|
||
|
|
static std::function<void()> middleClickCallback;
|
||
|
|
static std::function<void()> secondaryClickCallback;
|
||
|
|
static LRESULT CALLBACK MouseButtonsProc(int, WPARAM, LPARAM);
|
||
|
|
};
|