Deskflow 1.22.0.197
Keyboard and mouse sharing utility
Loading...
Searching...
No Matches
MSWindowsSession.h
Go to the documentation of this file.
1/*
2 * Deskflow -- mouse and keyboard sharing utility
3 * SPDX-FileCopyrightText: (C) 2013 - 2016 Symless Ltd.
4 * SPDX-License-Identifier: GPL-2.0-only WITH LicenseRef-OpenSSL-Exception
5 */
6
7#pragma once
8
9#include <string>
10
11#define WIN32_LEAN_AND_MEAN
12#include <Windows.h>
13
14#include <Tlhelp32.h>
15
17{
18public:
20 ~MSWindowsSession() = default;
21
27
28 bool isProcessInSession(const char *name, PHANDLE process);
29 HANDLE getUserToken(LPSECURITY_ATTRIBUTES security);
31
33 {
34 return m_activeSessionId;
35 }
36
37private:
38 BOOL nextProcessEntry(HANDLE snapshot, LPPROCESSENTRY32 entry);
39
40private:
41 DWORD m_activeSessionId;
42};
static const struct sockaddr FAR * name
Definition ArchNetworkWinsock.cpp:27
static const WSAEVENT FAR DWORD
Definition ArchNetworkWinsock.cpp:54
static const WSAEVENT FAR BOOL
Definition ArchNetworkWinsock.cpp:54
bool isProcessInSession(const char *name, PHANDLE process)
Definition MSWindowsSession.cpp:19
~MSWindowsSession()=default
HANDLE getUserToken(LPSECURITY_ATTRIBUTES security)
Definition MSWindowsSession.cpp:103
MSWindowsSession()
Definition MSWindowsSession.cpp:15
DWORD getActiveSessionId()
Definition MSWindowsSession.h:32
BOOL hasChanged()
Definition MSWindowsSession.cpp:124
void updateActiveSession()
Definition MSWindowsSession.cpp:129