Re: [patch] sawfish.wm.util.prompt
- From: matthew <matth love gmail com>
- To: sawfish-list gnome org
- Subject: Re: [patch] sawfish.wm.util.prompt
- Date: Thu, 17 Sep 2009 14:46:37 -0600
Jeremy Hankins wrote:
Matthew Love <matth love gmail com> writes:
Apparently, I forgot to update prompt-extras, which rename-window
calls, to the new definition of those functions from prompt.
Updated now and all in working order :)
First, it looks like prompt-for-file and prompt-for-directory need to be
updated too -- if `existing' is false then `prompt-validation-fun' is
nil.
But I also have a concern about the original patch. If I understand
what's going on, instead of testing to see if there is, e.g., a
validation/completion/whatever function provided, it actually calls it
to see if it returns non-nil. But there are times when calling the
function may be expensive. A common example might be accessing the
filesystem, though caching may handle that case adequately, I don't
know. But I also have stuff that completes on menu entries, which could
conceivably involve calling multiple other functions to expand submenus
-- some of which (if I ever get it working right) may even involve
communicating with other apps to fill in the menu. Is there a way to
silence the compiler warnings that doesn't involve extra calls to the
prompt-*-fun functions?
Sorry I didn't say something when the patch first passed through the
list.
Hm, yes, this is all true, and I see what you mean, this is certainly
not the best way to handle these functions in those modules...
The original code itself was fine really, other than the compilation
warnings generated by rep. I can't think of a solution for this at the
moment, but will look into it more when I have a system in front of me :)
Cheers,
Matthew
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]