Chris@49: /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */ Chris@28: Chris@28: /* Chris@52: Sonic Visualiser Chris@52: An audio file viewer and annotation editor. Chris@52: Centre for Digital Music, Queen Mary, University of London. Chris@52: This file copyright 2006 Chris Cannam. Chris@28: Chris@52: This program is free software; you can redistribute it and/or Chris@52: modify it under the terms of the GNU General Public License as Chris@52: published by the Free Software Foundation; either version 2 of the Chris@52: License, or (at your option) any later version. See the file Chris@52: COPYING included with this distribution for more information. Chris@28: */ Chris@28: Chris@28: #ifndef _PLAY_PARAMETER_REPOSITORY_H_ Chris@28: #define _PLAY_PARAMETER_REPOSITORY_H_ Chris@28: Chris@28: class PlayParameters; Chris@28: class Model; Chris@28: Chris@28: #include Chris@28: Chris@29: #include Chris@29: Chris@29: class PlayParameterRepository : public QObject Chris@28: { Chris@29: Q_OBJECT Chris@29: Chris@28: public: Chris@145: static PlayParameterRepository *getInstance(); Chris@28: Chris@28: virtual ~PlayParameterRepository(); Chris@28: Chris@30: void addModel(const Model *model); Chris@30: void removeModel(const Model *model); Chris@284: void copyParameters(const Model *from, const Model *to); Chris@30: Chris@284: PlayParameters *getPlayParameters(const Model *model); Chris@28: Chris@28: void clear(); Chris@28: Chris@29: signals: Chris@29: void playParametersChanged(PlayParameters *); Chris@57: void playPluginIdChanged(const Model *, QString); Chris@57: void playPluginConfigurationChanged(const Model *, QString); Chris@29: Chris@29: protected slots: Chris@29: void playParametersChanged(); Chris@57: void playPluginIdChanged(QString); Chris@57: void playPluginConfigurationChanged(QString); Chris@29: Chris@28: protected: Chris@57: typedef std::map ModelParameterMap; Chris@57: ModelParameterMap m_playParameters; Chris@28: Chris@28: static PlayParameterRepository *m_instance; Chris@28: }; Chris@28: Chris@28: #endif