Quantcast
Channel: Adobe Community : Popular Discussions - Photoshop Scripting
Viewing all articles
Browse latest Browse all 12244

what’s the notifier for starting the application

$
0
0

Recently I’ve been accidentally made aware of how to use notifiers in a thread in this Forum and a Feature Request-post seemed to provide a good example for using it.

The poster there was dissatisfied with Brushes.psp being updated on quitting, thus making users lose all newly created brush presets on crashing, unless one saved them manually in between.

 

Overwriting Brushes.psp seems a bit harsh, so I linked a Script that saves all brush presets as a new file »all.abr« into the Presets – Brushes-folder to »Mk  « for »Brsh«.

Another Script, which compares the change dates of »all.abr« and »Brushes.psp« and offers a confirm for loading »all.abr« in case it is the younger file, is linked to »Ntfy« but on starting Photoshop it is executed twice apparently.

(This is the code I used to set up the notifiers:

if(!app.notifiersEnabled) {app.notifiersEnabled = true};

app.notifiers.add("Mk  ", File("/Applications/Adobe%20Photoshop%20CS4/Presets/Scripts/saveBrushSetAll.jsx"), "Brsh");

app.notifiers.add("Ntfy", File("/Applications/Adobe%20Photoshop%20CS4/Presets/Scripts/loadBrushSetAll.jsx"));

)

 

So is »Ntfy« the wrong event or is there a likely reason within the Script itself that makes it run twice?

Any advice appreciated.


Viewing all articles
Browse latest Browse all 12244

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>