実装の概要

スキンの作成:
  1. ManageAssets プロジェクトにアクセスし、パッケージ com.adobe.solutions.cmg.manage.skins(CorrespondenceManagementSolutionTemplate\ManageAssets\src\com\adobe\solutions\cmg\manage\skins)に移動します。

  2. com.adobe.solutions.acm.authoring.skins.TextEditorSkin など、既存のスキンをコピーして、ホストコンポーネント com.adobe.solutions.acm.authoring.presentation.TextEditor の MXML スキン(CustomTextEditorSkin.mxml など)を作成します。

  3. MXML スキンを必要に応じて変更します。例えば、説明入力の高さを増やして、複数行にします。descrptionDesplay を TextArea に変更し、次のコードで高さを増やします。
    <s:TextInput id="descriptionDisplay"  enabled="true" enabled.View="false" width="205" height="24" />
    このコードを、次のように変更します。
    <s:TextArea id="descriptionDisplay"  enabled="true" enabled.View="false" width="205" height="54" />
    同様に、ダイアログフッターの色を変更するには、次のコードを更新します。
    <!-- footer background --> 
        <s:Rect bottom="1" left="1" right="1" height="{footerBar.height}" > 
             <s:fill > 
                 <s:LinearGradient rotation="90" > 
                     <s:GradientEntry color="0xe6e6e6"  /> 
                     <s:GradientEntry color="0xe0e0e0"  /> 
                 </s:LinearGradient> 
             </s:fill> 
        </s:Rect> 
        <s:Rect bottom="{footerBar.height-1}" left="1" right="1" height="1" > 
             <s:fill> 
                 <s:SolidColor color="0xd1d1d1"  /> 
             </s:fill> 
    </s:Rect>
    このコードを、次のように変更します。
    <!-- footer background --> 
        <s:Rect bottom="1" left="1" right="1" height="{footerBar.height}" > 
            <s:fill > 
                <s:LinearGradient rotation="90" > 
                    <s:GradientEntry color="0x3BB9FF"  /> 
                    <s:GradientEntry color="0xe0e0e0"  /> 
                </s:LinearGradient> 
            </s:fill> 
        </s:Rect> 
        <s:Rect bottom="{footerBar.height-1}" left="1" right="1" height="1" > 
            <s:fill> 
                <s:SolidColor color="0x3BB9FF"  /> 
            </s:fill> 
    </s:Rect>
  4. このスキンクラスを使用する CSS ファイルを作成し、その CSS をメインプロジェクトファイル index.mxml に追加します。次に例を示します。

    /* CSS file */ 
    @namespace s "library://ns.adobe.com/flex/spark"; 
    @namespace mx "library://ns.adobe.com/flex/mx"; 
    @namespace presentation "com.adobe.solutions.acm.authoring.presentation.*"; 
    @namespace custom "com.adobe.customizations"; 
    @namespace customizations "com.adobe.customizations.*"; 
    @namespace presentation1 "com.adobe.solutions.cmg.manage.presentation.*"; 
     
    presentation1|AssetEditorsStack 
    { 
        backgroundGradientStartColor: #FFFFFF; 
        backgroundGradientEndColor: #FFFFFF; 
        outerBorderColor: #000000; 
        outerBorderAlpha: .33; 
        skinClass: ClassReference("com.adobe.solutions.cmg.manage.skins.CustomTextEditorSkin"); 
        cornerRadius: 2; 
    }
  5. このカスタム CSS ファイルが index.mxml ファイルに含まれるように index.mxml を更新します(これは、他のすべての CSS ファイルの後に追加します)。
    <fx:Style source="/CSS/custom_styles.css"/>
  6. 再構築と再デプロイを行います。再構築および再デプロイについては、Solution Template の構築とデプロイを参照してください。