Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renamed and moved midi/GOMidiConfigurator to midi/objects/GOMidiObject #2093

Merged
merged 2 commits into from
Jan 20, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10,629 changes: 5,415 additions & 5,214 deletions ide-projects/NetBeans12/nbproject/configurations.xml

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/grandorgue/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Copyright 2006 Milan Digital Audio LLC
# Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
# Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
# License GPL-2.0 or later (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).

include(${CMAKE_SOURCE_DIR}/cmake/AddLinkerOption.cmake)
Expand Down Expand Up @@ -147,7 +147,6 @@ midi/ports/GOMidiRtPortFactory.cpp
midi/ports/GOMidiRtInPort.cpp
midi/ports/GOMidiRtOutPort.cpp
midi/GOMidi.cpp
midi/GOMidiConfigurator.cpp
midi/GOMidiInputMerger.cpp
midi/GOMidiListener.cpp
midi/GOMidiOutputMerger.cpp
Expand All @@ -159,6 +158,7 @@ midi/GOMidiShortcutPattern.cpp
midi/GOMidiShortcutReceiver.cpp
midi/GOMidiReceiver.cpp
midi/GOMidiRecorder.cpp
midi/objects/GOMidiObject.cpp
model/pipe-config/GOPipeConfig.cpp
model/pipe-config/GOPipeConfigNode.cpp
model/pipe-config/GOPipeConfigTreeNode.cpp
Expand Down
4 changes: 2 additions & 2 deletions src/grandorgue/control/GOButtonControl.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -19,7 +19,7 @@ GOButtonControl::GOButtonControl(
GOMidiReceiverType midi_type,
bool pushbutton,
bool isPiston)
: GOMidiConfigurator(organModel),
: GOMidiObject(organModel),
r_MidiMap(organModel.GetConfig().GetMidiMap()),
r_OrganModel(organModel),
m_midi(organModel, midi_type),
Expand Down
6 changes: 3 additions & 3 deletions src/grandorgue/control/GOButtonControl.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -10,10 +10,10 @@

#include <wx/string.h>

#include "midi/GOMidiConfigurator.h"
#include "midi/GOMidiReceiver.h"
#include "midi/GOMidiSender.h"
#include "midi/GOMidiShortcutReceiver.h"
#include "midi/objects/GOMidiObject.h"
#include "sound/GOSoundStateHandler.h"

#include "GOControl.h"
Expand All @@ -30,7 +30,7 @@ class GOButtonControl : public GOControl,
private GOEventHandler,
public GOSaveableObject,
public GOSoundStateHandler,
public GOMidiConfigurator {
public GOMidiObject {
private:
GOMidiMap &r_MidiMap;

Expand Down
4 changes: 2 additions & 2 deletions src/grandorgue/control/GOLabelControl.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2023 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -14,7 +14,7 @@
#include "config/GOConfig.h"

GOLabelControl::GOLabelControl(GOOrganController *organController)
: GOMidiConfigurator(*organController),
: GOMidiObject(*organController),
m_Name(),
m_Content(),
m_OrganController(organController),
Expand Down
6 changes: 3 additions & 3 deletions src/grandorgue/control/GOLabelControl.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -10,8 +10,8 @@

#include <wx/string.h>

#include "midi/GOMidiConfigurator.h"
#include "midi/GOMidiSender.h"
#include "midi/objects/GOMidiObject.h"
#include "sound/GOSoundStateHandler.h"

#include "GOControl.h"
Expand All @@ -24,7 +24,7 @@ class GOOrganController;
class GOLabelControl : public GOControl,
private GOSaveableObject,
private GOSoundStateHandler,
public GOMidiConfigurator {
public GOMidiObject {
protected:
wxString m_Name;
wxString m_Content;
Expand Down
24 changes: 12 additions & 12 deletions src/grandorgue/gui/dialogs/GOMidiListDialog.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2023 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -11,7 +11,7 @@
#include <wx/listctrl.h>
#include <wx/sizer.h>

#include "midi/GOMidiConfigurator.h"
#include "midi/objects/GOMidiObject.h"

#include "GOEvent.h"

Expand All @@ -28,7 +28,7 @@ GOMidiListDialog::GOMidiListDialog(
GODocumentBase *doc,
wxWindow *parent,
GODialogSizeSet &dialogSizes,
const std::vector<GOMidiConfigurator *> &midi_elements)
const std::vector<GOMidiObject *> &midi_elements)
: GOSimpleDialog(
parent,
wxT("MIDI Objects"),
Expand Down Expand Up @@ -70,7 +70,7 @@ GOMidiListDialog::GOMidiListDialog(
topSizer->Add(buttons, 0, wxALIGN_RIGHT | wxALL, 1);

for (unsigned i = 0; i < midi_elements.size(); i++) {
GOMidiConfigurator *obj = midi_elements[i];
GOMidiObject *obj = midi_elements[i];

m_Objects->InsertItem(i, obj->GetMidiType());
m_Objects->SetItemPtrData(i, (wxUIntPtr)obj);
Expand All @@ -87,14 +87,14 @@ GOMidiListDialog::GOMidiListDialog(
GOMidiListDialog::~GOMidiListDialog() {}

void GOMidiListDialog::OnButton(wxCommandEvent &event) {
GOMidiConfigurator *obj = (GOMidiConfigurator *)m_Objects->GetItemData(
m_Objects->GetFirstSelected());
GOMidiObject *obj
= (GOMidiObject *)m_Objects->GetItemData(m_Objects->GetFirstSelected());
obj->TriggerElementActions(event.GetId() - ID_BUTTON);
}

void GOMidiListDialog::OnStatus(wxCommandEvent &event) {
GOMidiConfigurator *obj = (GOMidiConfigurator *)m_Objects->GetItemData(
m_Objects->GetFirstSelected());
GOMidiObject *obj
= (GOMidiObject *)m_Objects->GetItemData(m_Objects->GetFirstSelected());
wxString status = obj->GetElementStatus();
GOMessageBox(
wxString::Format(_("Status: %s"), status),
Expand All @@ -105,8 +105,8 @@ void GOMidiListDialog::OnStatus(wxCommandEvent &event) {
void GOMidiListDialog::OnObjectClick(wxListEvent &event) {
m_Edit->Enable();
m_Status->Enable();
GOMidiConfigurator *obj = (GOMidiConfigurator *)m_Objects->GetItemData(
m_Objects->GetFirstSelected());
GOMidiObject *obj
= (GOMidiObject *)m_Objects->GetItemData(m_Objects->GetFirstSelected());
std::vector<wxString> actions = obj->GetElementActions();
for (unsigned i = 0; i < m_Buttons.size(); i++)
if (i < actions.size()) {
Expand All @@ -118,8 +118,8 @@ void GOMidiListDialog::OnObjectClick(wxListEvent &event) {
}

void GOMidiListDialog::OnObjectDoubleClick(wxListEvent &event) {
GOMidiConfigurator *obj = (GOMidiConfigurator *)m_Objects->GetItemData(
m_Objects->GetFirstSelected());
GOMidiObject *obj
= (GOMidiObject *)m_Objects->GetItemData(m_Objects->GetFirstSelected());
obj->ShowConfigDialog();
}

Expand Down
6 changes: 3 additions & 3 deletions src/grandorgue/gui/dialogs/GOMidiListDialog.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2023 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -17,7 +17,7 @@ class wxButton;
class wxListEvent;
class wxListView;

class GOMidiConfigurator;
class GOMidiObject;

class GOMidiListDialog : public GOSimpleDialog, public GOView {
private:
Expand Down Expand Up @@ -45,7 +45,7 @@ class GOMidiListDialog : public GOSimpleDialog, public GOView {
GODocumentBase *doc,
wxWindow *parent,
GODialogSizeSet &dialogSizes,
const std::vector<GOMidiConfigurator *> &midi_elements);
const std::vector<GOMidiObject *> &midi_elements);
~GOMidiListDialog();

DECLARE_EVENT_TABLE()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2023 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/

#include "GOMidiConfigurator.h"
#include "GOMidiObject.h"

#include <wx/intl.h>

#include "dialog-creator/GOMidiDialogCreator.h"
#include "midi/dialog-creator/GOMidiDialogCreator.h"

void GOMidiConfigurator::ShowConfigDialog() {
void GOMidiObject::ShowConfigDialog() {
const wxString &midiTypeCode = GetMidiTypeCode();
const wxString &midiName = GetMidiName();
wxString title
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2023 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/

#ifndef GOMIDICONFIGURATOR_H
#define GOMIDICONFIGURATOR_H
#ifndef GOMIDIOBJECT_H
#define GOMIDIOBJECT_H

#include <wx/string.h>

Expand All @@ -17,7 +17,7 @@ class GOMidiReceiverBase;
class GOMidiSender;
class GOMidiShortcutReceiver;

class GOMidiConfigurator {
class GOMidiObject {
private:
GOMidiDialogCreator &r_DialogCreator;

Expand All @@ -28,10 +28,10 @@ class GOMidiConfigurator {
virtual GOMidiSender *GetDivision() { return nullptr; }

public:
GOMidiConfigurator(GOMidiDialogCreator &dialogCreator)
GOMidiObject(GOMidiDialogCreator &dialogCreator)
: r_DialogCreator(dialogCreator) {}

virtual ~GOMidiConfigurator() {}
virtual ~GOMidiObject() {}

virtual const wxString &GetMidiTypeCode() const = 0;
virtual const wxString &GetMidiType() const = 0;
Expand Down
4 changes: 2 additions & 2 deletions src/grandorgue/model/GOEnclosure.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -16,7 +16,7 @@
#include "GOOrganModel.h"

GOEnclosure::GOEnclosure(GOOrganModel &organModel)
: GOMidiConfigurator(organModel),
: GOMidiObject(organModel),
r_OrganModel(organModel),
r_MidiMap(organModel.GetConfig().GetMidiMap()),
m_midi(organModel, MIDI_RECV_ENCLOSURE),
Expand Down
6 changes: 3 additions & 3 deletions src/grandorgue/model/GOEnclosure.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -11,10 +11,10 @@
#include <wx/string.h>

#include "control/GOControl.h"
#include "midi/GOMidiConfigurator.h"
#include "midi/GOMidiReceiver.h"
#include "midi/GOMidiSender.h"
#include "midi/GOMidiShortcutReceiver.h"
#include "midi/objects/GOMidiObject.h"
#include "sound/GOSoundStateHandler.h"

#include "GOEventHandler.h"
Expand All @@ -30,7 +30,7 @@ class GOEnclosure : public GOControl,
private GOEventHandler,
private GOSaveableObject,
private GOSoundStateHandler,
public GOMidiConfigurator {
public GOMidiObject {
private:
GOOrganModel &r_OrganModel;
GOMidiMap &r_MidiMap;
Expand Down
10 changes: 5 additions & 5 deletions src/grandorgue/model/GOEventHandlerList.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -17,7 +17,7 @@ class GOCombinationButtonSet;
class GOControl;
class GOControlChangedHandler;
class GOEventHandler;
class GOMidiConfigurator;
class GOMidiObject;
class GOReferencingObject;
class GOSoundStateHandler;
class GOSaveableObject;
Expand Down Expand Up @@ -61,7 +61,7 @@ class GOEventHandlerList {
UPVector<GOReferencingObject> m_ReferencingObjects;
UPVector<GOCombinationButtonSet> m_CombinationButtonSets;
UPVector<GOControlChangedHandler> m_ControlChangedHandlers;
UPVector<GOMidiConfigurator> m_MidiConfigurators;
UPVector<GOMidiObject> m_MidiConfigurators;
UPVector<GOEventHandler> m_MidiEventHandlers;
UPVector<GOSoundStateHandler> m_SoundStateHandlers;
UPVector<GOSaveableObject> m_SaveableObjects;
Expand All @@ -77,7 +77,7 @@ class GOEventHandlerList {
const {
return m_CombinationButtonSets.AsVector();
}
const std::vector<GOMidiConfigurator *> &GetMidiConfigurators() const {
const std::vector<GOMidiObject *> &GetMidiConfigurators() const {
return m_MidiConfigurators.AsVector();
}
const std::vector<GOEventHandler *> &GetMidiEventHandlers() const {
Expand Down Expand Up @@ -112,7 +112,7 @@ class GOEventHandlerList {
m_ControlChangedHandlers.Remove(handler);
}

void RegisterMidiConfigurator(GOMidiConfigurator *obj) {
void RegisterMidiConfigurator(GOMidiObject *obj) {
m_MidiConfigurators.Add(obj);
}

Expand Down
4 changes: 2 additions & 2 deletions src/grandorgue/model/GOManual.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright 2006 Milan Digital Audio LLC
* Copyright 2009-2024 GrandOrgue contributors (see AUTHORS)
* Copyright 2009-2025 GrandOrgue contributors (see AUTHORS)
* License GPL-2.0 or later
* (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html).
*/
Expand All @@ -21,7 +21,7 @@
#include "GOTremulant.h"

GOManual::GOManual(GOOrganModel &organModel)
: GOMidiConfigurator(organModel),
: GOMidiObject(organModel),
r_OrganModel(organModel),
r_MidiMap(organModel.GetConfig().GetMidiMap()),
m_group(wxT("---")),
Expand Down
Loading
Loading