mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 10:46:33 +02:00
23 lines
522 B
C
23 lines
522 B
C
|
|
#pragma once
|
||
|
|
#include <vector>
|
||
|
|
#include <unordered_set>
|
||
|
|
#include <string>
|
||
|
|
#include <Windows.h>
|
||
|
|
#include <UIAutomationClient.h>
|
||
|
|
|
||
|
|
struct TasklistButton {
|
||
|
|
std::wstring name;
|
||
|
|
long x, y, width, height, keynum;
|
||
|
|
};
|
||
|
|
|
||
|
|
class Tasklist {
|
||
|
|
public:
|
||
|
|
void update();
|
||
|
|
std::vector<TasklistButton> get_buttons();
|
||
|
|
bool update_buttons(std::vector<TasklistButton>& buttons);
|
||
|
|
private:
|
||
|
|
winrt::com_ptr<IUIAutomation> automation;
|
||
|
|
winrt::com_ptr<IUIAutomationElement> element;
|
||
|
|
winrt::com_ptr<IUIAutomationCondition> true_condition;
|
||
|
|
};
|