VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.h@ 57547

Last change on this file since 57547 was 57547, checked in by vboxsync, 9 years ago

FE/Qt: 7958: Adding yet another host-screen related wrapper to VBoxGlobal. Will be reused in other places.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 22.1 KB
Line 
1/* $Id: VBoxGlobal.h 57547 2015-08-26 11:04:28Z vboxsync $ */
2/** @file
3 * VBox Qt GUI - VBoxGlobal class declaration.
4 */
5
6/*
7 * Copyright (C) 2006-2014 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17
18#ifndef ___VBoxGlobal_h___
19#define ___VBoxGlobal_h___
20
21/* Qt includes: */
22#include <QApplication>
23#include <QLayout>
24#include <QMenu>
25#include <QStyle>
26#include <QHash>
27#include <QFileIconProvider>
28#include <QReadWriteLock>
29#ifdef Q_WS_MAC
30# include <QSet>
31#endif /* Q_WS_MAC */
32
33/* GUI includes: */
34#include "UIDefs.h"
35#include "UIMediumDefs.h"
36#include "VBoxGlobalSettings.h"
37#ifdef Q_WS_X11
38# include "VBoxX11Helper.h"
39#endif /* Q_WS_X11 */
40
41/* COM includes: */
42#include "VBox/com/Guid.h"
43#include "CHost.h"
44#include "CVirtualBoxClient.h"
45#include "CVirtualBox.h"
46#include "CSession.h"
47#include "CGuestOSType.h"
48
49/* Other includes: */
50#ifdef Q_WS_X11
51# include <X11/Xdefs.h>
52#endif /* Q_WS_X11 */
53
54/* Forward declarations: */
55class QAction;
56class QLabel;
57class QToolButton;
58class UIMachine;
59class CMachine;
60class CMedium;
61class CUSBDevice;
62class CHostVideoInputDevice;
63class QSpinBox;
64class UIMediumEnumerator;
65class UIMedium;
66class UIIconPoolGeneral;
67#ifdef Q_WS_X11
68class UIDesktopWidgetWatchdog;
69#endif /* Q_WS_X11 */
70
71// VBoxGlobal class
72////////////////////////////////////////////////////////////////////////////////
73
74class UISelectorWindow;
75class VBoxUpdateDlg;
76
77class VBoxGlobal : public QObject
78{
79 Q_OBJECT
80
81public:
82
83 /** VM launch modes. */
84 enum LaunchMode
85 {
86 LaunchMode_Default,
87 LaunchMode_Headless,
88 LaunchMode_Separate
89 };
90
91 /** Whether to start the VM running. */
92 enum StartRunning
93 {
94 StartRunning_Default, /**< Default (depends on debug settings). */
95 StartRunning_No, /**< Start the VM paused. */
96 StartRunning_Yes /**< Start the VM running. */
97 };
98
99 /* Static API: Create/destroy stuff: */
100 static VBoxGlobal* instance();
101 static void create();
102 static void destroy();
103
104 bool isValid() { return mValid; }
105 bool isCleaningUp() { return m_sfCleanupInProgress; }
106
107 static QString qtRTVersionString();
108 static uint qtRTVersion();
109 static QString qtCTVersionString();
110 static uint qtCTVersion();
111
112 QString vboxVersionString() const;
113 QString vboxVersionStringNormalized() const;
114
115 QString versionString() const { return mVerString; }
116 bool isBeta() const;
117
118 /** Returns whether GUI is separate (from VM) process. */
119 bool isSeparateProcess() const { return m_fSeparateProcess; }
120
121#ifdef Q_WS_MAC
122 static MacOSXRelease osRelease();
123#endif /* Q_WS_MAC */
124
125 /** Try to acquire COM cleanup protection token for reading. */
126 bool comTokenTryLockForRead() { return m_comCleanupProtectionToken.tryLockForRead(); }
127 /** Unlock previously acquired COM cleanup protection token. */
128 void comTokenUnlock() { return m_comCleanupProtectionToken.unlock(); }
129
130 /** Returns the copy of VirtualBox client wrapper. */
131 CVirtualBoxClient virtualBoxClient() const { return m_client; }
132 /** Returns the copy of VirtualBox object wrapper. */
133 CVirtualBox virtualBox() const { return m_vbox; }
134 /** Returns the copy of VirtualBox host-object wrapper. */
135 CHost host() const { return m_host; }
136 /** Returns the symbolic VirtualBox home-folder representation. */
137 QString homeFolder() const { return m_strHomeFolder; }
138
139 /** Returns the VBoxSVC availability value. */
140 bool isVBoxSVCAvailable() const { return m_fVBoxSVCAvailable; }
141
142 /** @name Host-screen geometry stuff
143 * @{ */
144 /** Returns the number of host-screens currently available on the system. */
145 int screenCount() const;
146
147 /** Returns the geometry of the host-screen with @a iHostScreenIndex.
148 * @note The default screen is used if @a iHostScreenIndex is -1. */
149 const QRect screenGeometry(int iHostScreenIndex = -1) const;
150 /** Returns the available-geometry of the host-screen with @a iHostScreenIndex.
151 * @note The default screen is used if @a iHostScreenIndex is -1. */
152 const QRect availableGeometry(int iHostScreenIndex = -1) const;
153
154 /** Returns the geometry of the host-screen which contains @a pWidget.
155 * @note The default screen is used if @a pWidget is 0. */
156 const QRect screenGeometry(QWidget *pWidget = 0) const;
157 /** Returns the available-geometry of the host-screen which contains @a pWidget.
158 * @note The default screen is used if @a pWidget is 0. */
159 const QRect availableGeometry(QWidget *pWidget = 0) const;
160 /** @} */
161
162 VBoxGlobalSettings &settings() { return gset; }
163 bool setSettings (VBoxGlobalSettings &gs);
164
165 UISelectorWindow &selectorWnd();
166
167 /** Returns current virtual machine. */
168 UIMachine* virtualMachine() const;
169 /** Returns currently active virtual machine window. */
170 QWidget* activeMachineWindow() const;
171
172 bool is3DAvailableWorker() const;
173 bool is3DAvailable() const { if (m3DAvailable < 0) return is3DAvailableWorker(); return m3DAvailable != 0; }
174
175#ifdef VBOX_GUI_WITH_PIDFILE
176 void createPidfile();
177 void deletePidfile();
178#endif
179
180 /* branding */
181 bool brandingIsActive (bool aForce = false);
182 QString brandingGetKey (QString aKey);
183
184 bool processArgs();
185
186 bool switchToMachine(CMachine &machine);
187
188 bool launchMachine(CMachine &machine, LaunchMode enmLaunchMode = LaunchMode_Default);
189
190 bool isVMConsoleProcess() const { return !vmUuid.isNull(); }
191 bool showStartVMErrors() const { return mShowStartVMErrors; }
192 QString managedVMUuid() const { return vmUuid; }
193 QList<QUrl> &argUrlList() { return m_ArgUrlList; }
194
195#ifdef Q_WS_X11
196 /** X11: Returns the type of the Window Manager we are running under. */
197 X11WMType typeOfWindowManager() const { return m_enmWindowManagerType; }
198#endif /* Q_WS_X11 */
199
200 /** Returns whether we should restore current snapshot before VM started. */
201 bool shouldRestoreCurrentSnapshot() const { return mRestoreCurrentSnapshot; }
202 /** Defines whether we should fRestore current snapshot before VM started. */
203 void setShouldRestoreCurrentSnapshot(bool fRestore) { mRestoreCurrentSnapshot = fRestore; }
204
205 bool hasFloppyImageToMount() const { return !m_strFloppyImage.isEmpty(); }
206 bool hasDvdImageToMount() const { return !m_strDvdImage.isEmpty(); }
207 QString const &getFloppyImage() const { return m_strFloppyImage; }
208 QString const &getDvdImage() const { return m_strDvdImage; }
209
210 bool isPatmDisabled() const { return mDisablePatm; }
211 bool isCsamDisabled() const { return mDisableCsam; }
212 bool isSupervisorCodeExecedRecompiled() const { return mRecompileSupervisor; }
213 bool isUserCodeExecedRecompiled() const { return mRecompileUser; }
214 bool areWeToExecuteAllInIem() const { return mExecuteAllInIem; }
215 bool isDefaultWarpPct() const { return mWarpPct == 100; }
216 uint32_t getWarpPct() const { return mWarpPct; }
217
218#ifdef VBOX_WITH_DEBUGGER_GUI
219 bool isDebuggerEnabled() const;
220 bool isDebuggerAutoShowEnabled() const;
221 bool isDebuggerAutoShowCommandLineEnabled() const;
222 bool isDebuggerAutoShowStatisticsEnabled() const;
223
224 RTLDRMOD getDebuggerModule() const { return m_hVBoxDbg; }
225#endif /* VBOX_WITH_DEBUGGER_GUI */
226
227 bool shouldStartPaused() const
228 {
229#ifdef VBOX_WITH_DEBUGGER_GUI
230 return m_enmStartRunning == StartRunning_Default ? isDebuggerAutoShowEnabled() : m_enmStartRunning == StartRunning_No;
231#else
232 return false;
233#endif
234 }
235
236 /* VBox enum to/from string/icon/color convertors */
237
238 QList <CGuestOSType> vmGuestOSFamilyList() const;
239 QList <CGuestOSType> vmGuestOSTypeList (const QString &aFamilyId) const;
240
241 /** Returns pixmap corresponding to passed @a strOSTypeID.
242 * In case if non-null @a pLogicalSize pointer provided, it will be updated properly. */
243 QPixmap vmGuestOSTypeIcon(const QString &strOSTypeID, QSize *pLogicalSize = 0) const;
244
245 CGuestOSType vmGuestOSType (const QString &aTypeId,
246 const QString &aFamilyId = QString::null) const;
247 QString vmGuestOSTypeDescription (const QString &aTypeId) const;
248
249 static inline QString yearsToString (uint32_t cVal)
250 {
251 return tr("%n year(s)", "", cVal);
252 }
253
254 static inline QString monthsToString (uint32_t cVal)
255 {
256 return tr("%n month(s)", "", cVal);
257 }
258
259 static inline QString daysToString (uint32_t cVal)
260 {
261 return tr("%n day(s)", "", cVal);
262 }
263
264 static inline QString hoursToString (uint32_t cVal)
265 {
266 return tr("%n hour(s)", "", cVal);
267 }
268
269 static inline QString minutesToString (uint32_t cVal)
270 {
271 return tr("%n minute(s)", "", cVal);
272 }
273
274 static inline QString secondsToString (uint32_t cVal)
275 {
276 return tr("%n second(s)", "", cVal);
277 }
278
279 QString differencingMediumTypeName() const { return mDiskTypes_Differencing; }
280
281 /**
282 * Similar to toString (KMediumType), but returns 'Differencing' for
283 * normal hard disks that have a parent.
284 */
285 QString mediumTypeString(const CMedium &medium) const;
286
287 QStringList COMPortNames() const;
288 QString toCOMPortName (ulong aIRQ, ulong aIOBase) const;
289 bool toCOMPortNumbers (const QString &aName, ulong &aIRQ, ulong &aIOBase) const;
290
291 QStringList LPTPortNames() const;
292 QString toLPTPortName (ulong aIRQ, ulong aIOBase) const;
293 bool toLPTPortNumbers (const QString &aName, ulong &aIRQ, ulong &aIOBase) const;
294
295 static bool hasAllowedExtension(const QString &strExt, const QStringList &extList)
296 {
297 for (int i = 0; i < extList.size(); ++i)
298 if (strExt.endsWith(extList.at(i), Qt::CaseInsensitive))
299 return true;
300 return false;
301 }
302
303 QIcon icon(QFileIconProvider::IconType type) { return m_globalIconProvider.icon(type); }
304 QIcon icon(const QFileInfo &info) { return m_globalIconProvider.icon(info); }
305
306 QPixmap warningIcon() const { return mWarningIcon; }
307 QPixmap errorIcon() const { return mErrorIcon; }
308
309 /* details generators */
310
311 QString details(const CMedium &medium, bool fPredictDiff, bool fUseHtml = true);
312
313 QString details (const CUSBDevice &aDevice) const;
314 QString toolTip (const CUSBDevice &aDevice) const;
315 QString toolTip (const CUSBDeviceFilter &aFilter) const;
316 QString toolTip(const CHostVideoInputDevice &webcam) const;
317
318 QString detailsReport (const CMachine &aMachine, bool aWithLinks);
319
320 /* VirtualBox helpers */
321
322 CSession openSession(const QString &aId, KLockType aLockType = KLockType_Write);
323
324 /** Shortcut to openSession (aId, true). */
325 CSession openExistingSession(const QString &aId) { return openSession(aId, KLockType_Shared); }
326
327#ifdef VBOX_GUI_WITH_NETWORK_MANAGER
328 void reloadProxySettings();
329#endif /* VBOX_GUI_WITH_NETWORK_MANAGER */
330
331 /* API: Medium-processing stuff: */
332 void createMedium(const UIMedium &medium);
333 void deleteMedium(const QString &strMediumID);
334 QString openMediumWithFileOpenDialog(UIMediumType mediumType, QWidget *pParent = 0,
335 const QString &strDefaultFolder = QString(), bool fUseLastFolder = true);
336 QString openMedium(UIMediumType mediumType, QString strMediumLocation, QWidget *pParent = 0);
337
338 /* API: Medium-enumeration stuff: */
339 void startMediumEnumeration(bool fForceStart = true);
340 bool agressiveCaching() const { return mAgressiveCaching; }
341 bool isMediumEnumerationInProgress() const;
342 UIMedium medium(const QString &strMediumID) const;
343 QList<QString> mediumIDs() const;
344
345 /** Prepares storage menu according passed parameters.
346 * @param menu QMenu being prepared.
347 * @param pListener Listener QObject, this menu being prepared for.
348 * @param pszSlotName SLOT in the @a pListener above, this menu will be handled with.
349 * @param machine CMachine object, this menu being prepared for.
350 * @param strControllerName The name of the CStorageController in the @a machine above.
351 * @param storageSlot The StorageSlot of the CStorageController called @a strControllerName above. */
352 void prepareStorageMenu(QMenu &menu,
353 QObject *pListener, const char *pszSlotName,
354 const CMachine &machine, const QString &strControllerName, const StorageSlot &storageSlot);
355 /** Updates @a constMachine storage with data described by @a target. */
356 void updateMachineStorage(const CMachine &constMachine, const UIMediumTarget &target);
357
358 /* various helpers */
359
360 QString languageName() const;
361 QString languageCountry() const;
362 QString languageNameEnglish() const;
363 QString languageCountryEnglish() const;
364 QString languageTranslators() const;
365
366 void retranslateUi();
367
368 /* public static stuff */
369
370 static bool isDOSType (const QString &aOSTypeId);
371
372 static QString languageId();
373 static void loadLanguage (const QString &aLangId = QString::null);
374 QString helpFile() const;
375
376 static void setTextLabel (QToolButton *aToolButton, const QString &aTextLabel);
377
378 static QRect normalizeGeometry (const QRect &aRectangle, const QRegion &aBoundRegion,
379 bool aCanResize = true);
380 static QRect getNormalized (const QRect &aRectangle, const QRegion &aBoundRegion,
381 bool aCanResize = true);
382 static QRegion flip (const QRegion &aRegion);
383
384 static void centerWidget (QWidget *aWidget, QWidget *aRelative,
385 bool aCanResize = true);
386
387 static QChar decimalSep();
388 static QString sizeRegexp();
389
390 static quint64 parseSize (const QString &);
391 static QString formatSize (quint64 aSize, uint aDecimal = 2, FormatSize aMode = FormatSize_Round);
392
393 static quint64 requiredVideoMemory(const QString &strGuestOSTypeId, int cMonitors = 1);
394
395 static QString locationForHTML (const QString &aFileName);
396
397 static QString highlight (const QString &aStr, bool aToolTip = false);
398
399 static QString replaceHtmlEntities(QString strText);
400 static QString emphasize (const QString &aStr);
401
402 static QString systemLanguageId();
403
404 static bool activateWindow (WId aWId, bool aSwitchDesktop = true);
405
406#ifdef Q_WS_X11
407 /** X11: Test whether the current window manager supports full screen mode. */
408 static bool supportsFullScreenMonitorsProtocolX11();
409 /** X11: Performs mapping of the passed @a pWidget to host-screen with passed @a uScreenId. */
410 static bool setFullScreenMonitorX11(QWidget *pWidget, ulong uScreenId);
411
412 /** X11: Returns a list of current _NET_WM_STATE flags for passed @a pWidget. */
413 static QVector<Atom> flagsNetWmState(QWidget *pWidget);
414 /** X11: Check whether _NET_WM_STATE_FULLSCREEN flag is set for passed @a pWidget. */
415 static bool isFullScreenFlagSet(QWidget *pWidget);
416 /** X11: Sets _NET_WM_STATE_FULLSCREEN flag for passed @a pWidget. */
417 static void setFullScreenFlag(QWidget *pWidget);
418#endif /* Q_WS_X11 */
419
420 static QString removeAccelMark (const QString &aText);
421
422 static QString insertKeyToActionText (const QString &aText, const QString &aKey);
423
424 static QPixmap joinPixmaps (const QPixmap &aPM1, const QPixmap &aPM2);
425
426 static QWidget *findWidget (QWidget *aParent, const char *aName,
427 const char *aClassName = NULL,
428 bool aRecursive = false);
429
430 static QList <QPair <QString, QString> > MediumBackends(KDeviceType enmDeviceType);
431 static QList <QPair <QString, QString> > HDDBackends();
432 static QList <QPair <QString, QString> > DVDBackends();
433 static QList <QPair <QString, QString> > FloppyBackends();
434
435 static QString documentsPath();
436
437#ifdef VBOX_WITH_VIDEOHWACCEL
438 static bool isAcceleration2DVideoAvailable();
439
440 /** additional video memory required for the best 2D support performance
441 * total amount of VRAM required is thus calculated as requiredVideoMemory + required2DOffscreenVideoMemory */
442 static quint64 required2DOffscreenVideoMemory();
443#endif
444
445#ifdef VBOX_WITH_CRHGSMI
446 static bool isWddmCompatibleOsType(const QString &strGuestOSTypeId);
447 static quint64 required3DWddmOffscreenVideoMemory(const QString &strGuestOSTypeId, int cMonitors = 1);
448#endif /* VBOX_WITH_CRHGSMI */
449
450 /* Returns full medium-format name for the given base medium-format name: */
451 static QString fullMediumFormatName(const QString &strBaseMediumFormatName);
452
453
454#ifdef RT_OS_LINUX
455 static void checkForWrongUSBMounted();
456#endif /* RT_OS_LINUX */
457
458 /* Shame on Qt it hasn't stuff for tuning
459 * widget size suitable for reflecting content of desired size.
460 * For example QLineEdit, QSpinBox and similar widgets should have a methods
461 * to strict the minimum width to reflect at least [n] symbols. */
462 static void setMinimumWidthAccordingSymbolCount(QSpinBox *pSpinBox, int cCount);
463
464signals:
465
466 /** Notifies listeners about the VBoxSVC availability change. */
467 void sigVBoxSVCAvailabilityChange();
468
469 /* Notifiers: Medium-processing stuff: */
470 void sigMediumCreated(const QString &strMediumID);
471 void sigMediumDeleted(const QString &strMediumID);
472
473 /* Notifiers: Medium-enumeration stuff: */
474 void sigMediumEnumerationStarted();
475 void sigMediumEnumerated(const QString &strMediumID);
476 void sigMediumEnumerationFinished();
477
478public slots:
479
480 bool openURL (const QString &aURL);
481
482 void sltGUILanguageChange(QString strLang);
483 void sltProcessGlobalSettingChange();
484
485protected slots:
486
487 /* Handlers: Prepare/cleanup stuff: */
488 void prepare();
489 void cleanup();
490
491 /** Handles the VBoxSVC availability change. */
492 void sltHandleVBoxSVCAvailabilityChange(bool fAvailable);
493
494protected:
495
496 bool eventFilter (QObject *, QEvent *);
497
498private:
499
500 /* Constructor/destructor: */
501 VBoxGlobal();
502 ~VBoxGlobal();
503
504#ifdef VBOX_WITH_DEBUGGER_GUI
505 void initDebuggerVar(int *piDbgCfgVar, const char *pszEnvVar, const char *pszExtraDataName, bool fDefault = false);
506 void setDebuggerVar(int *piDbgCfgVar, bool fState);
507 bool isDebuggerWorker(int *piDbgCfgVar, const char *pszExtraDataName) const;
508#endif
509
510 bool mValid;
511
512 /** COM cleanup protection token. */
513 QReadWriteLock m_comCleanupProtectionToken;
514
515 /** Holds the instance of VirtualBox client wrapper. */
516 CVirtualBoxClient m_client;
517 /** Holds the copy of VirtualBox object wrapper. */
518 CVirtualBox m_vbox;
519 /** Holds the copy of VirtualBox host-object wrapper. */
520 CHost m_host;
521 /** Holds the symbolic VirtualBox home-folder representation. */
522 QString m_strHomeFolder;
523
524 /** Holds the VBoxSVC availability value. */
525 bool m_fVBoxSVCAvailable;
526
527 VBoxGlobalSettings gset;
528
529 UISelectorWindow *mSelectorWnd;
530
531 /** Holds whether GUI is separate (from VM) process. */
532 bool m_fSeparateProcess;
533
534 QString vmUuid;
535 QList<QUrl> m_ArgUrlList;
536
537 /** Whether to show error message boxes for VM start errors. */
538 bool mShowStartVMErrors;
539
540 /* Variable: Medium-enumeration stuff: */
541 UIMediumEnumerator *m_pMediumEnumerator;
542 mutable QReadWriteLock m_mediumEnumeratorDtorRwLock;
543
544#ifdef Q_WS_X11
545 /** X11: Holds the type of the Window Manager we are running under. */
546 X11WMType m_enmWindowManagerType;
547
548 /** @name Host-screen geometry stuff
549 * @{ */
550 /** X11: Holds the desktop-widget watchdog instance aware of host-screen geometry changes. */
551 UIDesktopWidgetWatchdog *m_pDesktopWidgetWatchdog;
552 /** @} */
553#endif /* Q_WS_X11 */
554
555 /** The --aggressive-caching / --no-aggressive-caching option. */
556 bool mAgressiveCaching;
557 /** The --restore-current option. */
558 bool mRestoreCurrentSnapshot;
559
560 /** @name Ad-hoc VM reconfiguration.
561 * @{ */
562 /** Floppy image. */
563 QString m_strFloppyImage;
564 /** DVD image. */
565 QString m_strDvdImage;
566 /** @} */
567
568 /** @name VMM options
569 * @{ */
570 /** The --disable-patm option. */
571 bool mDisablePatm;
572 /** The --disable-csam option. */
573 bool mDisableCsam;
574 /** The --recompile-supervisor option. */
575 bool mRecompileSupervisor;
576 /** The --recompile-user option. */
577 bool mRecompileUser;
578 /** The --execute-all-in-iem option. */
579 bool mExecuteAllInIem;
580 /** The --warp-factor option value. */
581 uint32_t mWarpPct;
582 /** @} */
583
584#ifdef VBOX_WITH_DEBUGGER_GUI
585 /** Whether the debugger should be accessible or not.
586 * Use --dbg, the env.var. VBOX_GUI_DBG_ENABLED,
587 * --debug or the env.var. VBOX_GUI_DBG_AUTO_SHOW to enable. */
588 mutable int m_fDbgEnabled;
589 /** Whether to show the debugger automatically with the console.
590 * Use --debug or the env.var. VBOX_GUI_DBG_AUTO_SHOW to enable. */
591 mutable int m_fDbgAutoShow;
592 /** Whether to show the command line window when m_fDbgAutoShow is set. */
593 mutable int m_fDbgAutoShowCommandLine;
594 /** Whether to show the statistics window when m_fDbgAutoShow is set. */
595 mutable int m_fDbgAutoShowStatistics;
596 /** VBoxDbg module handle. */
597 RTLDRMOD m_hVBoxDbg;
598
599 /** Whether --start-running, --start-paused or nothing was given. */
600 enum StartRunning m_enmStartRunning;
601#endif
602
603#if defined (Q_WS_WIN32)
604 DWORD dwHTMLHelpCookie;
605#endif
606
607 QString mVerString;
608 QString mBrandingConfig;
609
610 int m3DAvailable;
611
612 QList <QString> mFamilyIDs;
613 QList <QList <CGuestOSType> > mTypes;
614
615 QString mDiskTypes_Differencing;
616
617 QString mUserDefinedPortName;
618
619 QPixmap mWarningIcon, mErrorIcon;
620
621 QFileIconProvider m_globalIconProvider;
622
623#ifdef VBOX_GUI_WITH_PIDFILE
624 QString m_strPidfile;
625#endif
626
627 char mSettingsPw[256];
628 bool mSettingsPwSet;
629
630 /** General icon-pool. */
631 UIIconPoolGeneral *m_pIconPool;
632
633 /* API: Instance stuff: */
634 static bool m_sfCleanupInProgress;
635 static VBoxGlobal* m_spInstance;
636 friend VBoxGlobal& vboxGlobal();
637};
638
639/* Shortcut to the static VBoxGlobal::instance() method: */
640inline VBoxGlobal& vboxGlobal() { return *VBoxGlobal::instance(); }
641
642#endif /* !___VBoxGlobal_h___ */
643
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette