aboutsummaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
Diffstat (limited to 'packages')
-rw-r--r--packages/patches/add_mxt_file_extension_support-0.41.4.patch72
1 files changed, 72 insertions, 0 deletions
diff --git a/packages/patches/add_mxt_file_extension_support-0.41.4.patch b/packages/patches/add_mxt_file_extension_support-0.41.4.patch
new file mode 100644
index 00000000..4fb7c90a
--- /dev/null
+++ b/packages/patches/add_mxt_file_extension_support-0.41.4.patch
@@ -0,0 +1,72 @@
+Index: u_main.tk
+===================================================================
+--- u_main.tk (revision 10595)
++++ u_main.tk (working copy)
+@@ -29,7 +29,8 @@
+ # set file types that open/save recognize
+ set filetypes {
+ {{Pd Files} {.pd} }
+- {{Max Text Files} {.pat} }
++ {{Max Patch Files} {.pat} }
++ {{Max Text Files} {.mxt} }
+ }
+ } elseif { $tcl_platform(os) == "Darwin" } {
+ set pd_nt 2
+@@ -47,7 +48,8 @@
+ # set file types that open/save recognize
+ set filetypes {
+ {{Pd Files} {.pd} }
+- {{Max Text Files (.pat)} {.pat} }
++ {{Max Patch Files (.pat)} {.pat} }
++ {{Max Text Files (.mxt)} {.mxt} }
+ }
+ } else {
+ set pd_nt 0
+@@ -65,7 +67,8 @@
+ # set file types that open/save recognize
+ set filetypes {
+ {{pd files} {.pd} }
+- {{max text files} {.pat} }
++ {{max patch files} {.pat} }
++ {{max text files} {.mxt} }
+ }
+ }
+
+Index: m_binbuf.c
+===================================================================
+--- m_binbuf.c (revision 10506)
++++ m_binbuf.c (working copy)
+@@ -870,7 +870,8 @@
+ if (*dir)
+ strcat(fbuf, dir), strcat(fbuf, "/");
+ strcat(fbuf, filename);
+- if (!strcmp(filename + strlen(filename) - 4, ".pat"))
++ if (!strcmp(filename + strlen(filename) - 4, ".pat") ||
++ !strcmp(filename + strlen(filename) - 4, ".mxt"))
+ {
+ x = binbuf_convert(x, 0);
+ deleteit = 1;
+@@ -1348,7 +1349,8 @@
+ void binbuf_evalfile(t_symbol *name, t_symbol *dir)
+ {
+ t_binbuf *b = binbuf_new();
+- int import = !strcmp(name->s_name + strlen(name->s_name) - 4, ".pat");
++ int import = !strcmp(name->s_name + strlen(name->s_name) - 4, ".pat") ||
++ !strcmp(name->s_name + strlen(name->s_name) - 4, ".mxt");
+ /* set filename so that new canvases can pick them up */
+ int dspstate = canvas_suspend_dsp();
+ glob_setfilename(0, name, dir);
+Index: g_readwrite.c
+===================================================================
+--- g_readwrite.c (revision 10497)
++++ g_readwrite.c (working copy)
+@@ -728,7 +728,8 @@
+ t_canvas *x2 = canvas_getrootfor(x);
+ char *name = x2->gl_name->s_name;
+ if (*name && strncmp(name, "Untitled", 8)
+- && (strlen(name) < 4 || strcmp(name + strlen(name)-4, ".pat")))
++ && (strlen(name) < 4 || strcmp(name + strlen(name)-4, ".pat")
++ || strcmp(name + strlen(name)-4, ".mxt")))
+ canvas_savetofile(x2, x2->gl_name, canvas_getdir(x2));
+ else canvas_menusaveas(x2);
+ }