Copy link to clipboard
Copied
In Photoshop, when you double click the Black and White eyedropper icon, it opens the respective color picker target dialog box.
I can see activity in the ScriptingListenerJS.log file but cannot seem to execute it through scripting.
This is the code that the ScriptingListenerJS.log displays.
Can anyone throw any light on this please.
// =======================================================
var idslct = charIDToTypeID( "slct" );
var desc43 = new ActionDescriptor();
var idnull = charIDToTypeID( "null" );
var ref18 = new ActionReference();
var ideyedropperTool = stringIDToTypeID( "eyedropperTool" );
ref18.putClass( ideyedropperTool );
desc43.putReference( idnull, ref18 );
var iddontRecord = stringIDToTypeID( "dontRecord" );
desc43.putBoolean( iddontRecord, true );
var idforceNotify = stringIDToTypeID( "forceNotify" );
desc43.putBoolean( idforceNotify, true );
executeAction( idslct, desc43, DialogModes.NO );
// =======================================================
var idmodalStateChanged = stringIDToTypeID( "modalStateChanged" );
var desc44 = new ActionDescriptor();
var idLvl = charIDToTypeID( "Lvl " );
desc44.putInteger( idLvl, 1 );
var idStte = charIDToTypeID( "Stte" );
var idStte = charIDToTypeID( "Stte" );
var identer = stringIDToTypeID( "enter" );
desc44.putEnumerated( idStte, idStte, identer );
var idkcanDispatchWhileModal = stringIDToTypeID( "kcanDispatchWhileModal" );
desc44.putBoolean( idkcanDispatchWhileModal, true );
var idTtl = charIDToTypeID( "Ttl " );
desc44.putString( idTtl, """Color Picker""" );
executeAction( idmodalStateChanged, desc44, DialogModes.NO );
Copy link to clipboard
Copied
Did not quite understand what you need.
But using this script Script Events Listener
it turns out about the following.
function select_35504150390625()
{
try {
var d = new ActionDescriptor();
var r = new ActionReference();
r.putClass(stringIDToTypeID("blackPointTool"));
d.putReference(stringIDToTypeID("null"), r);
d.putBoolean(stringIDToTypeID("dontRecord"), true);
d.putBoolean(stringIDToTypeID("forceNotify"), true);
executeAction(stringIDToTypeID("select"), d, DialogModes.NO);
}
catch (e) { throw(e); }
}
function select_81561279296875()
{
try {
var d = new ActionDescriptor();
var r = new ActionReference();
r.putClass(stringIDToTypeID("whitePointTool"));
d.putReference(stringIDToTypeID("null"), r);
d.putBoolean(stringIDToTypeID("dontRecord"), true);
d.putBoolean(stringIDToTypeID("forceNotify"), true);
executeAction(stringIDToTypeID("select"), d, DialogModes.NO);
}
catch (e) { throw(e); }
}