ChangeListener.h
Go to the documentation of this file.
#pragma once
#include <set>
#include <globjects/globjects_api.h>
namespace globjects
{
class Changeable;
class GLOBJECTS_API ChangeListener
{
friend class Changeable;
public:
virtual ~ChangeListener();
virtual void notifyChanged(const Changeable * sender);
private:
std::set<Changeable*> m_subjects;
void addSubject(Changeable * subject);
void removeSubject(Changeable * subject);
};
} // namespace globjects
globjects
Contains all the classes that wrap OpenGL functionality.
globjects::ChangeListener
Allows listening to any Changeable.
Definition: ChangeListener.h:22
globjects::Changeable
Superclass of all objects that want others to signal that they have changed.
Definition: Changeable.h:22