X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=sidebyside;f=source%2Fstate.h;fp=source%2Fstate.h;h=6cbe152ead5fdbd41a230b1cf668b2c5f9c9bad8;hb=c1f038acb91eb3bfaa34dfd4729d19ed3f871a42;hp=0000000000000000000000000000000000000000;hpb=1b5097c11b1226e14e23a0827c5238ba5d3ba444;p=libs%2Fgltk.git diff --git a/source/state.h b/source/state.h new file mode 100644 index 0000000..6cbe152 --- /dev/null +++ b/source/state.h @@ -0,0 +1,31 @@ +#ifndef MSP_GLTK_STATE_H_ +#define MSP_GLTK_STATE_H_ + +#include +#include + +namespace Msp { +namespace GLtk { + +enum State +{ + NORMAL, //< Default state + HOVER, //< Pointer over the widget + ACTIVE, //< Widget is active (e.g. pressed button) + DISABLED, //< Widget is unresponsive + N_STATES_ //< Sentry value +}; + +extern std::istream &operator>>(std::istream &, State &); + +} // namespace GLtk + +namespace Parser { + +template<> +struct TypeResolver { static const Value::Type type=Value::ENUM; }; + +} // namespace Parser +} // namespace Msp + +#endif