VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/src/globals/UIStarter.h@ 72361

Last change on this file since 72361 was 72361, checked in by vboxsync, 7 years ago

FE/Qt: bugref:9049: Small cleanup for UIStarter: Removing sltDestroyUI, it's the only part of cleanup anyway.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.0 KB
Line 
1/* $Id: UIStarter.h 72361 2018-05-28 16:39:19Z vboxsync $ */
2/** @file
3 * VBox Qt GUI - UIStarter class declaration.
4 */
5
6/*
7 * Copyright (C) 2018 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 ___UIStarter_h___
19#define ___UIStarter_h___
20
21/* Qt includes: */
22#include <QObject>
23
24/** QObject subclass allowing to control GUI part
25 * of VirtualBox application in sync/async modes. */
26class UIStarter : public QObject
27{
28 Q_OBJECT;
29
30 /** Constructs UI starter. */
31 UIStarter();
32 /** Destructs UI starter. */
33 virtual ~UIStarter() /* override */;
34
35public:
36
37 /** Returns the singleton UI starter instance. */
38 static UIStarter *instance() { return s_pInstance; }
39
40 /** Create the singleton UI starter instance. */
41 static void create();
42 /** Create the singleton UI starter instance. */
43 static void destroy();
44
45 /** Init VBoxGlobal connections. */
46 void init();
47 /** Deinit VBoxGlobal connections. */
48 void deinit();
49
50private slots:
51
52 /** Prepares everything. */
53 void prepare();
54
55 /** Starts corresponding part of the UI. */
56 void sltStartUI();
57 /** Restarts corresponding part of the UI. */
58 void sltRestartUI();
59
60 /** Cleanups everything. */
61 void cleanup();
62
63 /** Opens URLs in Selector UI. */
64 void sltOpenURLs();
65
66 /** Handles commit data request. */
67 void sltHandleCommitDataRequest();
68
69private:
70
71 /** Holds the singleton UI starter instance. */
72 static UIStarter *s_pInstance;
73};
74
75/** Singleton UI starter 'official' name. */
76#define gStarter UIStarter::instance()
77
78#endif /* !___UIStarter_h___ */
Note: See TracBrowser for help on using the repository browser.

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