//2009-09-18 とりあえず。PhotoShopの最初のパスを決め打ち。
#include 'c.js';
#target 'indesign';
(function(){

c('selection').each(function(){
	c((this.constructor.name== 'Image' || this.constructor.name== 'EPS') ? this : this.allGraphics).each(function(){
		//
		try{
		//clippingTypeの値で振り分け
		switch(this.clippingPath.clippingType){
			　//Photoshopパス
			  case 1886613620 : 
			  
			  break;
			  
			  //エッジの検出
			  case 1685349735 : 
			  
			  break;
			  
			  //アルファチャンネル
			  case 1634756707 : 
			  
			  break;
			  
			  //ユーザーによるパスの修正
			  case 1970106484 : 
			  
			  break;
			  
			  //なし
		      case 1852796517 :
				this.hasOwnProperty ('clippingPath') &&  this.clippingPath.appliedPathName = this.clippingPath.photoshopPathNames[0];
			  break;
		  }
		}catch(e){
		$.writeln(e);	
		}
	});
});
})();