APMS POPUP UI Guide

1. Push Popup UI 구조

1.1 UI 상세구조


Image 삽입 구조

enter image description here


Default 기본 항목


Image 적용 요소

APMSPopup APmsPopup = APMS.getPopUpInstance();
APmsPopup.setXmlAndDefaultFlag(false);

// Popup Layout Setting 
APmsPopup.setPopupBackImgResource("pms_bg_popup");
        
// Top Layout Setting
APmsPopup.setTopLayoutFlag(true);
APmsPopup.setTopBackColor(56, 98, 196, 255);
APmsPopup.setTopTitleType("image");
APmsPopup.setTopTitleImgResource("pms_img_logo");
        
// Content Layout Setting
APmsPopup.setContentBackColor(255, 255, 255, 255);
APmsPopup.setContentTextColor(0, 0, 0);
    
// Bottom Button Layout Setting
APmsPopup.setBottomTextBtnCount(2);
APmsPopup.setBottomRichBtnCount(1);
APmsPopup.setBottomBackColor(224, 224, 224, 255);
    
APmsPopup.setBottomTextViewFlag(true);
APmsPopup.setBottomTextBtnCount(2);
APmsPopup.setBottomRichBtnCount(1);
APmsPopup.setBottomBtnTextName("닫  기", "자세히 보기");
APmsPopup.setBottomBtnTextColor(255, 255, 255);
APmsPopup.setBottomBtnImageResource("pms_btn_text_close_off", "pms_btn_text_detail_off");
APmsPopup.setTextBottomBtnClickListener(btnEvent1, btnEvent2);
APmsPopup.setRichBottomBtnClickListener(btnEvent1);
APmsPopup.setRichLinkTouchListener(touchEvent)
    
APmsPopup.commit();

Text Popup XML 기본 구조

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:gravity="center">
    
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#f0f0f0"
        android:orientation="vertical" >
    
        <TextView 
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:layout_gravity="center"
            android:gravity="center"
            android:background="#FF3862C4"
            android:padding="10dp"
            android:text="ASP"/>
    
        <ScrollView
            android:layout_width="match_parent"
            android:layout_height="0dp"
            android:layout_weight="1.0"
            android:background="#FFFFFFFF" >
    
            <TextView
                android:id="@+id/pms_txt_msg"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:tag="ContentTextView"
                android:padding="10dp"
                android:textColor="#FF222A3B" />
        </ScrollView>
    
        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_gravity="bottom"
            android:background="#FFE0E0E0"
            android:gravity="center"
            android:orientation="horizontal" >
    
            <LinearLayout
                android:id="@+id/pms_btn_close"
                android:layout_width="100dp"
                android:layout_height="wrap_content"
                android:layout_margin="10dp"
                android:background="#f3f3f3"
                android:clickable="true"
                android:gravity="center"
                android:orientation="horizontal"
                android:padding="10dp" >
    
                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_gravity="center_vertical"
                    android:layout_marginLeft="10dp"
                    android:tag="button1"
                    android:text="닫기"
                    android:textColor="#FF000000" />
            </LinearLayout>
    
            <LinearLayout
                android:id="@+id/pms_btn_detail"
                android:layout_width="100dp"
                android:layout_height="wrap_content"
                android:layout_margin="10dp"
                android:background="#f3f3f3"
                android:clickable="true"
                android:gravity="center"
                android:padding="10dp" >
    
                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:tag="button2"
                    android:text="자세히 보기"
                    android:textColor="#FF000000" />
            </LinearLayout>
        </LinearLayout>
    </LinearLayout>
</RelativeLayout>

Rich Popup XML 기본 구조

<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:background="#f8f8f8"
    android:gravity="center" >
    
    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:paddingBottom="20dp"
        android:gravity="center" >
    
        <ImageView
            android:id="@+id/pms_img"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_margin="3dp"
            android:scaleType="centerCrop" />
    
        <WebView
            android:id="@+id/pms_wv"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:tag="ContentWebView"
            android:layout_margin="3dp" />
    
        <ProgressBar
            android:id="@+id/pms_prg"
            style="?android:attr/progressBarStyleHorizontal"
            android:tag="ContentProgressBar"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_gravity="center_horizontal"
            android:layout_margin="4dp" />
    </RelativeLayout>
    
    <LinearLayout
        android:id="@+id/pms_btn_close"
        android:layout_width="100dp"
        android:layout_height="wrap_content"
        android:layout_margin="10dp"
        android:background="#f3f3f3"
        android:clickable="true"
        android:gravity="center"
        android:orientation="horizontal"
        android:padding="10dp" >
    
        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="center_vertical"
            android:layout_marginLeft="10dp"
            android:tag="button1"
            android:text="닫기"
            android:textColor="#FF000000" />
    </LinearLayout>
</FrameLayout>

XML 삽입 구조

APMSPopup APmsPopup = APMS.getPopUpInstance();
APmsPopup.setXmlAndDefaultFlag(true);

APmsPopup.setLayoutXMLTextResId("pms_text_popup");
APmsPopup.setXMLTextButtonType("TextView", "TextView");
APmsPopup.setXMLTextButtonTagName("button1", "button2");
            
APmsPopup.setLayoutXMLRichResId("pms_rich_popup");
APmsPopup.setXMLRichButtonType("TextView");
APmsPopup.setXMLRichButtonTagName("button1");
        
APmsPopup.setTextBottomBtnClickListener(btnEvent1, btnEvent2);
APmsPopup.setRichBottomBtnClickListener(btnEvent1);
APmsPopup.setRichLinkTouchListener(touchEvent);
        
APmsPopup.commit();

필수 사항