[Gridflow-cvs] [svn] commit: r6040 - in /trunk/src: classes2.cxx hack.hxx

svn-gridflow at artengine.ca svn-gridflow at artengine.ca
Wed Aug 11 22:22:20 EDT 2010


Author: matju
Date: Wed Aug 11 22:22:20 2010
New Revision: 6040

Log:
move canvas_reflecttitle out of our code

Added:
    trunk/src/hack.hxx
Modified:
    trunk/src/classes2.cxx

Modified: trunk/src/classes2.cxx
==============================================================================
--- trunk/src/classes2.cxx (original)
+++ trunk/src/classes2.cxx Wed Aug 11 22:22:20 2010
@@ -164,36 +164,7 @@
   switch (t) {Z(A_FLOAT)Z(A_SYMBOL)Z(A_POINTER)Z(A_DOLLAR)Z(A_DOLLSYM)Z(A_COMMA)Z(A_SEMI)Z(A_LIST)Z(A_GRID)Z(A_GRIDOUT)
   default: return "unknown type";}}
 #undef Z
-
-#if 1 /* included from Pd 41, sorry */
-static void canvas_reflecttitle(t_canvas *x)
-{
-    char namebuf[MAXPDSTRING];
-    t_canvasenvironment *env = canvas_getenv(x);
-    if (env->ce_argc)
-    {
-        int i;
-        strcpy(namebuf, " (");
-        for (i = 0; i < env->ce_argc; i++)
-        {
-            if (strlen(namebuf) > MAXPDSTRING/2 - 5)
-                break;
-            if (i != 0)
-                strcat(namebuf, " ");
-            atom_string(&env->ce_argv[i], namebuf + strlen(namebuf),
-                MAXPDSTRING/2);
-        }
-        strcat(namebuf, ")");
-    }
-    else namebuf[0] = 0;
-    sys_vgui("wm title .x%lx {%s%c%s - %s}\n",
-        x, x->gl_name->s_name, (x->gl_dirty? '*' : ' '), namebuf,
-            canvas_getdir(x)->s_name);
-}
-#else
-extern "C" void canvas_reflecttitle (t_glist *);
-#endif
-
+#include "hack.hxx"
 #define binbuf_addv(B,S,A...) binbuf_addv(B,const_cast<char *>(S),A)
 #define BOF t_binbuf *b = ((t_object *)canvas)->te_binbuf; if (!b) RAISE("no parent for canvas containing [setargs]");
 \class GFSetArgs : FObject {



More information about the Gridflow-cvs mailing list