Shortcut Buttons Panel: Photoshop Persistent
The fourth part of the Shortcut Buttons Panel is creating an Photoshop Persistent call. The result is allowing the Adobe Photoshop Panel to continue running and communicating to Adobe Photoshop even if it is closed or minimized.
Instructions:
- The red colored text are the changes made to the
initfunction in ShortcutButtons.mxml:public function init():void{ CSXSInterface.instance.evalScript("PhotoshopPersistent"); newDocTimer.addEventListener(TimerEvent.TIMER,newDocTimeHandler); closeDocTimer.addEventListener(TimerEvent.TIMER,closeDocTimeHandler); newDocTimer.start(); closeDocTimer.start(); }Code Walkthrough: Adding
CSXSInterface.instance.evalScript("PhotoshopPersistent");to theinitfunction will allow the Shortcut Buttons Panel to continue communicating with Adobe Photoshop even when the panel is closed. Note: For more information aboutPhotoshopPersistent, see Adobe Photoshop Reserved Words. - Go to Run > Run ShortcutButtons to preview the design area in the web browser.
Note: The buttons and checkboxes will not work in the web browser because the target is Adobe Photoshop. - Close the web browser.
- Close Adobe Flex Builder.
- Open the ShortcutButtons folder on the desktop.

- Open the bin-debug folder.

- Copy ShortcutButtons.swf into the Panels folder under the Adobe Photoshop CS5\Plug-ins\ folder located under:
- Applications for Macintosh
- Program Files for Windows
- Copy ShortcutButtons.jsx from the Panels folder into the bin-debug folder under the ShortcutButtons folder on the Desktop.
- Open Adobe Photoshop.
- Go to Windows > Extensions > ShortcutButtons.
- The Shortcut Buttons Panel opens as a panel like seen below:

- The Shortcut Buttons Panel has two buttons and two checkboxes in which the user can create a new document and close a current document manually by clicking on the buttons or automatically on a timer. When the Shortcut Buttons Panel is closed or minimized, communication to Adobe Photoshop will continue if the two check boxes are marked.