<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android">

    <data>

        <variable
            name="entity"
            type="com.gh.gamecenter.entity.ServerCalendarEntity" />

        <variable
            name="isCloseBottom"
            type="Boolean" />

        <variable
            name="position"
            type="Integer" />

        <variable
            name="clickListener"
            type="com.gh.gamecenter.common.callback.OnViewClickListener" />

        <import type="android.text.TextUtils" />

        <import type="com.gh.gamecenter.core.utils.DisplayUtils" />
    </data>

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:focusable="true"
        android:focusableInTouchMode="true"
        android:orientation="horizontal">

        <EditText
            android:id="@+id/kaifu_add_time"
            addKaiFuPosition="@{position}"
            addKaiFuTime="@{entity.time}"
            kaiFuTextColor="@{entity.dataMark}"
            kaiFuTextPosition="@{position}"
            android:layout_width="0dp"
            android:layout_height="52dp"
            android:layout_weight="80"
            android:background="@drawable/bg_add_kaifu"
            android:focusable="false"
            android:gravity="center"
            android:maxLines="2"
            android:onClick="@{(v)-> clickListener.onClick(v, position)}"
            android:textSize="11sp" />

        <EditText
            android:id="@+id/kaifu_add_first_name"
            kaiFuTextColor="@{entity.dataMark}"
            kaiFuTextPosition="@{position}"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="104"
            android:layout_marginStart="-1dp"
            android:layout_marginEnd="-1dp"
            android:background="@drawable/bg_add_kaifu"
            android:focusable="@{position == 0? false: true}"
            android:gravity="center"
            android:hint="点击填写"
            android:onClick="@{(v)-> clickListener.onClick(v, position)}"
            android:singleLine="true"
            android:text="@={entity.firstName}"
            android:textColorHint="@color/title"
            android:textSize="12sp" />

        <EditText
            android:id="@+id/kaifu_add_server_name"
            kaiFuTextColor="@{entity.dataMark}"
            kaiFuTextPosition="@{position}"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="132"
            android:background="@drawable/bg_add_kaifu"
            android:focusable="@{position == 0? false: true}"
            android:gravity="center"
            android:hint="点击填写"
            android:onClick="@{(v)-> clickListener.onClick(v, position)}"
            android:singleLine="true"
            android:text="@={entity.serverName}"
            android:textColorHint="@{position == 0? @color/hint:@color/title}"
            android:textSize="12sp" />

    </LinearLayout>
</layout>
