コード例 #1
0
    public void ReleaseEmojiItem(int i)
    {
        PhotoStudioEmojiItem item = m_installItemList[i];

        item.ReleaseItem();
        m_installItemList.RemoveAt(i);
    }
コード例 #2
0
 public void SetEmojiItemEditorMode(PhotoStudioEmojiItem item, bool isActive = true)
 {
     for (int i = 0; i < m_installItemList.Count; i++)
     {
         m_installItemList[i].EditorMode = m_installItemList[i].Equals(item) ? isActive : false;
     }
 }
コード例 #3
0
    public void ReleaseEmojiItem(PhotoStudioEmojiItem item)
    {
        item.ReleaseItem();
        if (m_installItemList.Contains(item))
        {
            m_installItemList.Remove(item);
        }

        m_workTimeline.AddBeforeTimeline(new PhotoStudioWorkTimeline.Timeline(PHOTOSTUDIO_WORK_TYPE.TYPE_DELETE, item));
    }
コード例 #4
0
    public void SetEmojiItemSortTop(PhotoStudioEmojiItem item)
    {
        int depth = 0;

        for (int i = 0; i < m_installItemList.Count; i++)
        {
            depth = Mathf.Max(depth, m_installItemList[i].GetIcon.depth);
        }

        m_workTimeline.AddBeforeTimeline(new PhotoStudioWorkTimeline.Timeline(PHOTOSTUDIO_WORK_TYPE.TYPE_SORT, item));
        item.UpdateDepth(depth + 1);
    }
コード例 #5
0
        public Timeline(PHOTOSTUDIO_WORK_TYPE type, PhotoStudioEmojiItem item)
        {
            this.m_type = type;

            this.m_item = item;

            this.m_position = item.transform.localPosition;
            this.m_rotate   = item.GetIcon.transform.localRotation;

            this.m_spriteName = item.GetIcon.spriteName;
            this.m_spriteSize = Mathf.Max(item.GetIcon.width, item.GetIcon.height);
            this.m_depth      = item.GetIcon.depth;
        }
コード例 #6
0
        public Timeline(Timeline item)
        {
            this.m_type = item.m_type;

            this.m_item = item.m_item;

            this.m_position = item.m_position;
            this.m_rotate   = item.m_rotate;

            this.m_spriteName = item.m_spriteName;
            this.m_spriteSize = item.m_spriteSize;
            this.m_depth      = item.m_depth;

            this.m_filter = item.m_filter;
        }
コード例 #7
0
        public Timeline(PHOTOSTUDIO_WORK_TYPE type, PhotoStudioEmojiItem item, Vector3 position, Quaternion rotate,
                        string spriteName, int spriteSize, int depth, ImageFilterInfo filter)
        {
            this.m_type = type;

            this.m_item = item;

            this.m_position = position;
            this.m_rotate   = rotate;

            this.m_spriteName = spriteName;
            this.m_spriteSize = spriteSize;
            this.m_depth      = depth;

            this.m_filter = filter;
        }
コード例 #8
0
    public void SetEmojiItem(EmojiInfo info)
    {
        if (m_installItemList.Count < MAX_EMOJI_COUNT)
        {
            int depth = 0;
            for (int i = 0; i < m_installItemList.Count; i++)
            {
                depth = Mathf.Max(depth, m_installItemList[i].GetIcon.depth);
            }

            PhotoStudioEmojiItem item = m_emojiItemList[m_getItemCount];
            m_getItemCount = (m_getItemCount + 1).Equals(MAX_EMOJI_COUNT) ? 0 : m_getItemCount + 1;

            m_installItemList.Add(item);

            item.ActiveItem(info, depth + 1);

            m_workTimeline.AddBeforeTimeline(new PhotoStudioWorkTimeline.Timeline(PHOTOSTUDIO_WORK_TYPE.TYPE_ADD, item));
            m_workTimeline.ReleaseAfterTimeline();

            m_uiWindow.CloseEmojiPopup();
        }
    }