diff options
Diffstat (limited to 'externals/grill/flext/source/flclass.h')
-rw-r--r-- | externals/grill/flext/source/flclass.h | 62 |
1 files changed, 31 insertions, 31 deletions
diff --git a/externals/grill/flext/source/flclass.h b/externals/grill/flext/source/flclass.h index 6b361cc7..6536590f 100644 --- a/externals/grill/flext/source/flclass.h +++ b/externals/grill/flext/source/flclass.h @@ -527,9 +527,19 @@ protected: //! Dump an attribute to the attribute outlet bool DumpAttrib(const char *attr) const { return DumpAttrib(MakeSymbol(attr)); } - /*! \addtogroup FLEXT_C_INOUT + //! List attributes + int ListAttrib(AtomList &a) const; + //! Get an attribute value + bool GetAttrib(const t_symbol *s,AtomList &a) const; + //! Set an attribute value + bool SetAttrib(const t_symbol *s,const AtomList &a) { return SetAttrib(s,a.Count(),a.Atoms()); } + + //! List methods + int ListMethods(AtomList &a,int inlet = 0) const; + +/*! \addtogroup FLEXT_C_INOUT @{ - */ +*/ //! \brief get a code for a list of inlets or outlets unsigned long XletCode(xlet::type tp = xlet::tp_none,...); // end list with 0 (= tp_none) !! @@ -558,6 +568,7 @@ protected: //! @} FLEXT_C_INOUT + // method handling public: @@ -641,6 +652,8 @@ protected: bool IsGet() const { return (flags&afl_getset) == afl_get; } bool IsSet() const { return (flags&afl_getset) == afl_set; } bool BothExist() const { return (flags&afl_bothexist) != 0; } + void SetSave(bool s) { if(s) flags |= afl_save; else flags &= ~afl_save; } + bool IsSaved() const { return (flags&afl_save) != 0; } int flags; metharg argtp; @@ -732,9 +745,7 @@ private: itemarr *attrhead,*clattrhead; - attritem *FindAttr(const t_symbol *tag,bool get) const; - int ListAttr(AtomList &a) const; - int ListMeth(AtomList &a,int inlet = 0) const; + attritem *FindAttrib(const t_symbol *tag,bool get,bool msg = false) const; static int CheckAttrib(int argc,const t_atom *argv); bool InitAttrib(int argc,const t_atom *argv); @@ -742,47 +753,36 @@ private: bool ListMethods(int inlet = 0) const; bool ListAttrib() const; bool GetAttrib(attritem *a); + bool GetAttrib(attritem *a,AtomList &l) const; bool SetAttrib(const t_symbol *s,int argc,const t_atom *argv); bool SetAttrib(attritem *a,int argc,const t_atom *argv); + void SetAttribSave(attritem *a,bool save); + bool GetAttribSave(attritem *a) const { return a->IsSaved(); } + static bool cb_ListMethods(flext_base *c,int argc,const t_atom *argv); static bool cb_ListAttrib(flext_base *c) { return c->ListAttrib(); } // queue stuff -// class qmsg; -// static qmsg *qhead,*qtail; - + //! Start message queue + static void StartQueue(); //! Flush messages in the queue static void QFlush(flext_base *th = NULL); - //! Queue worker function -// static void QWork(bool qlock,bool syslock); +#if FLEXT_SYS == FLEXT_SYS_PD - //! Start message queue - static void StartQueue(); -#if FLEXT_SYS == FLEXT_SYS_JMAX -// static void QTick(int winlet = 0, fts_symbol_t s = NULL, int ac = 0, const fts_atom_t *at = NULL); -#else // PD or Max -// static void QTick(); -#ifndef FLEXT_QTHR -// static t_qelem *qclk; -#else - //! Queue worker thread function -// static void *QWorker(void *); - //! Queue worker thread conditional -// static ThrCond qthrcond; -#endif -#endif +#if !defined(FLEXT_NOATTREDIT) + // attribute editor + static void SetAttrEditor(t_classid c); -// static void Queue(qmsg *m); -#ifdef FLEXT_THREADS -// static ThrMutex qmutex; + static bool cb_AttrDialog(flext_base *c,int argc,const t_atom *argv); + static void cb_GfxProperties(t_gobj *c, t_glist *); + static void cb_GfxVis(t_gobj *c, t_glist *gl, int vis); + static void cb_GfxSave(t_gobj *c, t_binbuf *b); #endif - -#if FLEXT_SYS == FLEXT_SYS_PD - // proxy object (for additional inlets) stuff + // proxy object (for additional inlets) static t_class *px_class; struct px_object // no virtual table! |