Changeset View
Changeset View
Standalone View
Standalone View
processui/ProcessModel_p.h
Show All 16 Lines | 1 | /* | |||
---|---|---|---|---|---|
17 | along with this library; see the file COPYING.LIB. If not, write to | 17 | along with this library; see the file COPYING.LIB. If not, write to | ||
18 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 18 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||
19 | Boston, MA 02110-1301, USA. | 19 | Boston, MA 02110-1301, USA. | ||
20 | */ | 20 | */ | ||
21 | 21 | | |||
22 | #ifndef PROCESSMODEL_P_H_ | 22 | #ifndef PROCESSMODEL_P_H_ | ||
23 | #define PROCESSMODEL_P_H_ | 23 | #define PROCESSMODEL_P_H_ | ||
24 | 24 | | |||
25 | #include <processcore/process.h> | 25 | #include <processcore/extended_process_list.h> | ||
26 | #include "ProcessModel.h" | 26 | #include "ProcessModel.h" | ||
27 | 27 | | |||
28 | #include <kuser.h> | 28 | #include <kuser.h> | ||
29 | #include <QPixmap> | 29 | #include <QPixmap> | ||
30 | #include <QObject> | 30 | #include <QObject> | ||
31 | #include <QList> | 31 | #include <QList> | ||
32 | #include <QVariant> | 32 | #include <QVariant> | ||
33 | #include <QHash> | 33 | #include <QHash> | ||
▲ Show 20 Lines • Show All 143 Lines • ▼ Show 20 Line(s) | 148 | #endif | |||
177 | 177 | | |||
178 | bool mSimple; //< In simple mode, the model returns everything as flat, with no icons, etc. This is set by changing cmbFilter | 178 | bool mSimple; //< In simple mode, the model returns everything as flat, with no icons, etc. This is set by changing cmbFilter | ||
179 | 179 | | |||
180 | QTime mLastUpdated; ///< Time that we last updated the processes. | 180 | QTime mLastUpdated; ///< Time that we last updated the processes. | ||
181 | 181 | | |||
182 | long long mMemTotal; ///< the total amount of physical memory in kb in the machine. We can used this to determine the percentage of memory an app is using | 182 | long long mMemTotal; ///< the total amount of physical memory in kb in the machine. We can used this to determine the percentage of memory an app is using | ||
183 | int mNumProcessorCores; ///< The number of (enabled) processor cores in the this machine | 183 | int mNumProcessorCores; ///< The number of (enabled) processor cores in the this machine | ||
184 | 184 | | |||
185 | KSysGuard::Processes *mProcesses; ///< The processes instance | 185 | KSysGuard::ExtendedProcesses *mProcesses; ///< The processes instance | ||
186 | 186 | | |||
187 | QPixmap mBlankPixmap; ///< Used to pad out process names which don't have an icon | 187 | QPixmap mBlankPixmap; ///< Used to pad out process names which don't have an icon | ||
188 | 188 | | |||
189 | /** Show the process command line options in the process name column */ | 189 | /** Show the process command line options in the process name column */ | ||
190 | bool mShowCommandLineOptions; | 190 | bool mShowCommandLineOptions; | ||
191 | 191 | | |||
192 | bool mShowingTooltips; | 192 | bool mShowingTooltips; | ||
193 | bool mNormalizeCPUUsage; | 193 | bool mNormalizeCPUUsage; | ||
Show All 9 Lines | |||||
203 | int mTimerId; | 203 | int mTimerId; | ||
204 | QList<long> mPidsToUpdate; ///< A list of pids that we need to emit dataChanged() for regularly | 204 | QList<long> mPidsToUpdate; ///< A list of pids that we need to emit dataChanged() for regularly | ||
205 | 205 | | |||
206 | static const int MAX_HIST_ENTRIES = 100; | 206 | static const int MAX_HIST_ENTRIES = 100; | ||
207 | static const int MIN_HIST_AGE = 200; ///< If the latest history entry is at least this ms old, a new one gets added | 207 | static const int MIN_HIST_AGE = 200; ///< If the latest history entry is at least this ms old, a new one gets added | ||
208 | /** Storage for the history entries. We need one per percentage column. */ | 208 | /** Storage for the history entries. We need one per percentage column. */ | ||
209 | QHash<KSysGuard::Process *, QVector<ProcessModel::PercentageHistoryEntry>> mMapProcessCPUHistory; | 209 | QHash<KSysGuard::Process *, QVector<ProcessModel::PercentageHistoryEntry>> mMapProcessCPUHistory; | ||
210 | 210 | | |||
211 | QVector<KSysGuard::ProcessAttribute*> mExtraAttributes; | ||||
212 | | ||||
211 | #ifdef HAVE_XRES | 213 | #ifdef HAVE_XRES | ||
212 | bool mHaveXRes; ///< True if the XRes extension is available at run time | 214 | bool mHaveXRes; ///< True if the XRes extension is available at run time | ||
213 | QMap<qlonglong, XID> mXResClientResources; | 215 | QMap<qlonglong, XID> mXResClientResources; | ||
214 | #endif | 216 | #endif | ||
215 | 217 | | |||
216 | bool mMovingRow; | 218 | bool mMovingRow; | ||
217 | bool mRemovingRow; | 219 | bool mRemovingRow; | ||
218 | bool mInsertingRow; | 220 | bool mInsertingRow; | ||
219 | 221 | | |||
220 | bool mIsX11; | 222 | bool mIsX11; | ||
221 | 223 | | |||
222 | ProcessModel* q; | 224 | ProcessModel* q; | ||
223 | }; | 225 | }; | ||
224 | 226 | | |||
225 | #endif | 227 | #endif |