all repos — fluxbox @ 6cfa087536abf3328cabbe867df978309034edc9

custom fork of the fluxbox windowmanager

Make FbTk::MemFun[12] inherit from std::unary/binary_function

this way, they can be used as inputs to std::bind1st and friends
Pavel Labath pavelo@centrum.sk
commit

6cfa087536abf3328cabbe867df978309034edc9

parent

2024f258b66ead778b7c5e048e29967cfe7e8bf2

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

jump to
M src/FbTk/MemFun.hhsrc/FbTk/MemFun.hh

@@ -22,6 +22,7 @@

#ifndef FBTK_MEM_FUN_HH #define FBTK_MEM_FUN_HH +#include <functional> #include "SelectArg.hh" namespace FbTk {

@@ -55,7 +56,7 @@ }

/// One argument functor template <typename ReturnType, typename Object, typename Arg1> -class MemFun1 { +class MemFun1: public std::unary_function<Arg1, ReturnType> { public: typedef ReturnType (Object:: *Action)(Arg1);

@@ -82,7 +83,7 @@ }

/// Two argument functor template <typename ReturnType, typename Object, typename Arg1, typename Arg2> -class MemFun2 { +class MemFun2: public std::binary_function<Arg1, Arg2, ReturnType> { public: typedef ReturnType (Object:: *Action)(Arg1,Arg2);