Browse Source

Remove alternative constructor for SourcesEditor

master
Krisjanis Rijnieks 9 years ago
parent
commit
e947c13525
  1. 11
      src/UserInterface/SourcesEditor.cpp
  2. 5
      src/UserInterface/SourcesEditor.h

11
src/UserInterface/SourcesEditor.cpp

@ -5,8 +5,7 @@ namespace piMapper {
SourcesEditor::SourcesEditor(){
init();
// Create new MediaServer instance,
// we will need to clear this in the deconstr
mediaServer = new MediaServer();
isMediaServerExternal = false;
addMediaServerListeners();
@ -21,14 +20,6 @@ void SourcesEditor::init(){
isMediaServerExternal = false;
}
SourcesEditor::SourcesEditor(MediaServer * externalMediaServer){
init();
// Assign external MediaServer instance pointer
mediaServer = externalMediaServer;
isMediaServerExternal = true;
addMediaServerListeners();
}
SourcesEditor::~SourcesEditor(){
//unregisterAppEvents();
delete imageSelector;

5
src/UserInterface/SourcesEditor.h

@ -13,12 +13,7 @@ namespace piMapper {
class SourcesEditor {
public:
// Default contructor that initializes media server locally,
// thus requiring to delete the media server from memory on deconstr
SourcesEditor();
// Alternative constructor that allows to assign external media server
SourcesEditor(MediaServer * externalMediaServer);
~SourcesEditor();
void setup();

Loading…
Cancel
Save