all repos — fluxbox @ bda94a6c1acea846e2269512fa601eceef80b737

custom fork of the fluxbox windowmanager

const-correct on Resource class
fluxgen fluxgen
commit

bda94a6c1acea846e2269512fa601eceef80b737

parent

e296c91a188c9e66cb4fd13c3986fc17e7179db1

1 files changed, 3 insertions(+), 1 deletions(-)

jump to
M src/Resource.hhsrc/Resource.hh

@@ -19,7 +19,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Resource.hh,v 1.4 2002/04/04 14:26:47 fluxgen Exp $ +// $Id: Resource.hh,v 1.5 2002/05/17 10:59:58 fluxgen Exp $ #ifndef RESOURCE_HH #define RESOURCE_HH

@@ -74,7 +74,9 @@ inline Resource<T>& operator = (const T& newvalue) { m_value = newvalue; return *this;}

std::string getString(); inline T& operator*(void) { return m_value; } + inline const T& operator*(void) const { return m_value; } inline T *operator->(void) { return &m_value; } + inline const T *operator->(void) const { return &m_value; } private: T m_value, m_defaultval; ResourceManager &m_rm;