0

フォトショップ用のファイル形式プラグインを作成していますが、チェックボックスのコンボボックスなどのロードと保存のオプションを含むウィンドウをポップアップする必要があります。これを行うにはどうすればよいですか?

4

1 に答える 1

1

Adobeの最新のSDKには、ダイアログとウィンドウの使用例が多数含まれています。

SaveまたはオプションではSave As、プラグインはformatSelectorOptionsStartパラメータを処理し、そのコード ブロックでオプション ダイアログを開く必要があります。

アクションではOpen、オプションを要求する通常の方法はありませんが (どのようなオプションを要求しますか?)、ダイアログを表示できるイベントformatSelectorFilterFileにはformatSelectorReadPrepare、、、、、およびformatSelectorReadStartformatSelectorReadContinueformatSelectorReadFinish

以下は、さまざまなセレクターを処理するプラグインへのエントリ ポイントの例です。

DLLExport MACPASCAL void PluginMain(
  const int16 selector,
  PIPickerParams* pParams,
  intptr_t * data,
  int16 * result)
{
    switch(selector)
    {
        case formatSelectorAbout:
            // display about dialog
            break;
        case formatSelectorReadPrepare:
            // prepare to read in file - adjust memory
            break;
        case formatSelectorReadStart:
            // begin interaction regarding reading 
            // dialog here if needed
            break;
        case formatSelectorReadContinue:
        case formatSelectorReadFinish:
        case formatSelectorOptionsPrepare:
            // handle each appropriately
            break;
        case formatSelectorOptionsStart:
            // HERE is where you'd open your window
            // with options, etc.
            break;
        // etc.
        // etc.
        // etc.
    }
}
于 2009-06-09T19:02:23.730 に答える