AntiMicroX
autoprofileinfo.h
Go to the documentation of this file.
1 /* antimicrox Gamepad to KB+M event mapper
2  * Copyright (C) 2015 Travis Nickles <nickles.travis@gmail.com>
3  * Copyright (C) 2020 Jagoda Górska <juliagoda.pl@protonmail>
4  *
5  * This program is free software: you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation, either version 3 of the License, or
8  * (at your option) any later version.
9 
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14 
15  * You should have received a copy of the GNU General Public License
16  * along with this program. If not, see <http://www.gnu.org/licenses/>.
17  */
18 
19 #ifndef AUTOPROFILEINFO_H
20 #define AUTOPROFILEINFO_H
21 
22 #include <QObject>
23 
29 class AutoProfileInfo : public QObject
30 {
31  Q_OBJECT
32 
33  public:
34  explicit AutoProfileInfo(QString uniqueID, QString profileLocation, bool active, bool partialTitle, QObject *parent);
35  explicit AutoProfileInfo(QString uniqueID, QString profileLocation, QString exe, bool active, bool partialTitle,
36  QObject *parent);
37  explicit AutoProfileInfo(QObject *parent);
39 
40  void setUniqueID(QString guid);
41  QString getUniqueID() const;
42 
43  void setProfileLocation(QString profileLocation);
44  QString getProfileLocation() const;
45 
46  void setExe(QString exe);
47  QString getExe() const;
48 
49  void setWindowClass(QString windowClass);
50  QString getWindowClass() const;
51 
52  void setWindowName(QString winName);
53  QString getWindowName() const;
54 
55  void setActive(bool active);
56  bool isActive();
57 
58  void setDeviceName(QString name);
59  QString getDeviceName() const;
60 
61  void setDefaultState(bool value);
62  bool isCurrentDefault();
63 
64  void setPartialState(bool value);
65  bool isPartialState();
66 
67  QString toString() const;
68 
69  private:
70  QString uniqueID; // unique ID of assigned controller (all, when none)
71  QString profileLocation;
72  QString exe;
73  QString deviceName;
74  QString windowClass;
75  QString windowName;
76  bool active;
79 };
80 
81 Q_DECLARE_METATYPE(AutoProfileInfo *)
82 
83 #endif // AUTOPROFILEINFO_H
AutoProfileInfo::setDeviceName
void setDeviceName(QString name)
Definition: autoprofileinfo.cpp:119
AutoProfileInfo::getExe
QString getExe() const
Definition: autoprofileinfo.cpp:97
AutoProfileInfo::toString
QString toString() const
Definition: autoprofileinfo.cpp:133
AutoProfileInfo::getUniqueID
QString getUniqueID() const
Definition: autoprofileinfo.cpp:58
AutoProfileInfo::setWindowClass
void setWindowClass(QString windowClass)
Definition: autoprofileinfo.cpp:99
AutoProfileInfo::profileLocation
QString profileLocation
Definition: autoprofileinfo.h:71
AutoProfileInfo::setWindowName
void setWindowName(QString winName)
Definition: autoprofileinfo.cpp:103
AutoProfileInfo::setPartialState
void setPartialState(bool value)
Definition: autoprofileinfo.cpp:129
AutoProfileInfo::defaultState
bool defaultState
Definition: autoprofileinfo.h:77
AutoProfileInfo::exe
QString exe
Definition: autoprofileinfo.h:72
AutoProfileInfo::setProfileLocation
void setProfileLocation(QString profileLocation)
Definition: autoprofileinfo.cpp:60
AutoProfileInfo::uniqueID
QString uniqueID
Definition: autoprofileinfo.h:70
AutoProfileInfo::setExe
void setExe(QString exe)
Definition: autoprofileinfo.cpp:75
AutoProfileInfo::active
bool active
Definition: autoprofileinfo.h:76
AutoProfileInfo::getDeviceName
QString getDeviceName() const
Definition: autoprofileinfo.cpp:121
AutoProfileInfo::deviceName
QString deviceName
Definition: autoprofileinfo.h:73
AutoProfileInfo::isCurrentDefault
bool isCurrentDefault()
is this autoprofile loaded by default? There is one default profile for all of controllers and there ...
Definition: autoprofileinfo.cpp:117
AutoProfileInfo::setActive
void setActive(bool active)
Definition: autoprofileinfo.cpp:107
AutoProfileInfo::setDefaultState
void setDefaultState(bool value)
Definition: autoprofileinfo.cpp:111
AutoProfileInfo::setUniqueID
void setUniqueID(QString guid)
Definition: autoprofileinfo.cpp:56
AutoProfileInfo::AutoProfileInfo
AutoProfileInfo(QString uniqueID, QString profileLocation, bool active, bool partialTitle, QObject *parent)
Definition: autoprofileinfo.cpp:36
AutoProfileInfo::partialState
bool partialState
Definition: autoprofileinfo.h:78
AutoProfileInfo::windowClass
QString windowClass
Definition: autoprofileinfo.h:74
AutoProfileInfo::windowName
QString windowName
Definition: autoprofileinfo.h:75
AutoProfileInfo::getWindowClass
QString getWindowClass() const
Definition: autoprofileinfo.cpp:101
AutoProfileInfo::getProfileLocation
QString getProfileLocation() const
Definition: autoprofileinfo.cpp:73
AutoProfileInfo::isActive
bool isActive()
Definition: autoprofileinfo.cpp:109
AutoProfileInfo::isPartialState
bool isPartialState()
Definition: autoprofileinfo.cpp:131
AutoProfileInfo::getWindowName
QString getWindowName() const
Definition: autoprofileinfo.cpp:105
AutoProfileInfo::~AutoProfileInfo
~AutoProfileInfo()
Definition: autoprofileinfo.cpp:54
autoprofileinfo.h
AutoProfileInfo
Links information about targeted application with recommended profile.
Definition: autoprofileinfo.h:29