[TxMt] callback.application.did-deactivate
Trevor Harmon
trevor at vocaro.com
Wed Dec 21 09:52:02 UTC 2011
From the 8956 release notes:
"Introduced callback.application.did-activate and callback.application.did-deactivate as two new semantic classes. A command with this class will be executed when the application gain/lose focus. The scope selector is matched against the “current scope” of the visible document (in each window). This allows creating a command with “Save” set to “Modified Documents” and thereby recreating TextMate 1.x’s ability to save modified documents on lost focus."
Has anyone gotten this to work? In my personal bundle, I created a new command called "Save files when focus is lost", set the Semantic Class to "callback.application.did-deactivate", set Save to "Modified Documents", and Input to "Nothing". But the files never save. Can't think what I'm doing wrong.
By the way, the command shows up in the Bundles menu, even though there's no point to having it there. Is there a way to keep the command enabled and active but off the menu?
Thanks,
Trevor
More information about the textmate
mailing list