Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#5527: With the GroupDialog instance getter as the only service left,…
… the UIManager is now demoted to a GroupDialogManager.
- Loading branch information
1 parent
ad50338
commit 79e6118
Showing
11 changed files
with
79 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,34 @@ | ||
#pragma once | ||
|
||
#include "imodule.h" | ||
#include "igroupdialog.h" | ||
|
||
// Forward declarations | ||
class IGroupDialog; // see igroupdialog.h for definition | ||
|
||
const char* const MODULE_UIMANAGER("UIManager"); | ||
namespace ui | ||
{ | ||
|
||
/** | ||
* greebo: The UI Manager gives access to the GroupDialog and the DialogManager. | ||
*/ | ||
class IUIManager : | ||
class IGroupDialogManager : | ||
public RegisterableModule | ||
{ | ||
public: | ||
virtual IGroupDialog& getGroupDialog() = 0; | ||
virtual ~IGroupDialogManager() {} | ||
|
||
virtual IGroupDialog& get() = 0; | ||
}; | ||
|
||
inline IUIManager& GlobalUIManager() | ||
} | ||
|
||
constexpr const char* const MODULE_GROUPDIALOG("GroupDialogModule"); | ||
|
||
inline ui::IGroupDialogManager& GlobalGroupDialogManager() | ||
{ | ||
static module::InstanceReference<IUIManager> _reference(MODULE_UIMANAGER); | ||
static module::InstanceReference<ui::IGroupDialogManager> _reference(MODULE_GROUPDIALOG); | ||
return _reference; | ||
} | ||
|
||
inline IGroupDialog& GlobalGroupDialog() | ||
{ | ||
return GlobalUIManager().getGroupDialog(); | ||
return GlobalGroupDialogManager().get(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters