I am assuming this is Yvan, good to see you submitting more patches.
Patches that are pasting to text fields have high failure rates. Can you attach the patch as a file? Also, if you log in before submitting the patch, you'll automatically get email updates about the status of the patch, and we don't have to guess who submitted it :-)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
this patch should fix that.
From 1b2db5e4348149b1cb7fa58fd62518a20a4d8550 Mon Sep 17 00:00:00 2001
From: Yvan Volochine <yvan.volochine@gmail.com>
Date: Tue, 15 Mar 2011 04:04:09 +0100
Subject: [PATCH] fix: check for recent file existence
---
tcl/wheredoesthisgo.tcl | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/tcl/wheredoesthisgo.tcl b/tcl/wheredoesthisgo.tcl
index 1e9e034..60b70fd 100644
--- a/tcl/wheredoesthisgo.tcl
+++ b/tcl/wheredoesthisgo.tcl
@@ -6,7 +6,10 @@ package provide wheredoesthisgo 0.1
proc open_file {filename} {
set directory [file normalize [file dirname $filename]]
set basename [file tail $filename]
- if {[regexp -nocase -- "\.(pd|pat|mxt)$" $filename]} {
+ if {
+ [file exists $filename] == 1
+ && [regexp -nocase -- "\.(pd|pat|mxt)$" $filename]
+ } then {
::pdtk_canvas::started_loading_file [format "%s/%s" $basename $filename]
pdsend "pd open [enquote_path $basename] [enquote_path $directory]"
# remove duplicates first, then the duplicate added after to the top
@@ -16,7 +19,7 @@ proc open_file {filename} {
set ::recentfiles_list [lrange $::recentfiles_list 0 $::total_recentfiles]
::pd_menus::update_recentfiles_menu
} {
- ::pdwindow::post [format [_ "Ignoring '%s': doesn't look like a Pd-file"] $filename]
+ ::pdwindow::post [format [_ "Ignoring '%s': doesn't exist or look like a Pd-file"] $filename]
}
}
--
1.7.4.1
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
sorry for the bad formatting...
the patch is there:
http://pastebin.com/AhC3U5ti
I am assuming this is Yvan, good to see you submitting more patches.
Patches that are pasting to text fields have high failure rates. Can you attach the patch as a file? Also, if you log in before submitting the patch, you'll automatically get email updates about the status of the patch, and we don't have to guess who submitted it :-)