dialogue window under the cursor

Anyone, especially newbies, asking for help with Photoshop Scripting and Photoshop Automation - as opposed to those contributing to discussion about an aspect of Photoshop Scripting

Moderators: Tom, Kukurykus

tyr

dialogue window under the cursor

Post by tyr »

Hi everyone!

Is there a way to open new dialogue window unter the cursor?
Code: Select all#target photoshop
var dlg = new Window("dialog{text:'Brushes',bounds:[0,0,250,183],\
    br01:IconButton{bounds:[6,6,57,57], icon:'/Applications/Adobe Photoshop CS5/Presets/Scripts/Brushes/01.png',properties:{style:'button'}},\
//more buttons
};");

dlg.br01.onClick = function ( ) {
    dlg.close(1);
    brSelect('! RA');
}

//more buttins

dlg.center();
dlg.show();

function brSelect(brush){
//script selects tool preset
}