Beispiel #1
0
        private void LateUpdate()
        {
        #if !UNITY_EDITOR
            try
            {
        #endif

            if (mFlag)
            {
                if (Layout)
                {
                    Layout.ResetLayout();
                }
                mFlag = false;
            }

        #if !UNITY_EDITOR
        }

        catch (Exception ex)
        {
            Logger.Error(ex.ToString());
        }
        #endif
        }
Beispiel #2
0
        private void LateUpdate()
        {
#if !UNITY_EDITOR
            try
            {
#endif

            if (mRefreshTitle)
            {
                if (LayoutTitle != null)
                {
                    LayoutTitle.ResetLayout();
                }
                mRefreshTitle = false;
            }

#if !UNITY_EDITOR
        }

        catch (Exception ex)
        {
            Logger.Error(ex.ToString());
        }
#endif
        }
Beispiel #3
0
        private void LateUpdate()
        {
        #if !UNITY_EDITOR
            try
            {
        #endif
            if (isEnable)
            {
                isEnable            = false;
                ChatMessages.height = 0;
                ChatMessages.ResetLayout();
                var pos = chatMessageTrans.localPosition;
                var h   = ChatMessages.height - 80;
                chatMessageTrans.localPosition = new Vector3(pos.x, h, pos.z);

                SetHornPostion();
            }

        #if !UNITY_EDITOR
        }

        catch (Exception ex)
        {
            Logger.Error(ex.ToString());
        }
        #endif
        }
Beispiel #4
0
        private void LateUpdate()
        {
        #if !UNITY_EDITOR
            try
            {
        #endif

            if (mRefleshLayOut)
            {
                if (mStackLayout != null)
                {
                    mStackLayout.ResetLayout();
                }
                mRefleshLayOut = false;
            }

        #if !UNITY_EDITOR
        }

        catch (Exception ex)
        {
            Logger.Error(ex.ToString());
        }
        #endif
        }
Beispiel #5
0
 private void OnEvent_UpdateMission(IEvent ievent)
 {
     if (null != MissionLayout)
     {
         MissionLayout.ResetLayout();
     }
 }
Beispiel #6
0
        IEnumerator DelayReposition()
        {
            yield return(new WaitForEndOfFrame());

            if (mStackLayout != null)
            {
                mStackLayout.ResetLayout();
            }
        }
Beispiel #7
0
 public void Listen <T>(T message)
 {
     if (message is string && (message as string) == "ActiveChanged")
     {
         Layout.ResetLayout();
         var transform = Layout.transform;
         var pos       = transform.localPosition;
         var h         = Layout.height - Background.height / 2;
         transform.localPosition = new Vector3(pos.x, h, pos.z);
     }
 }
Beispiel #8
0
    protected override void DrawCustomProperties()
    {
        NGUIEditorTools.DrawProperty("Offset", serializedObject, "mOffset", GUILayout.MinWidth(20f));
        NGUIEditorTools.DrawProperty("Padding", serializedObject, "mPadding", GUILayout.MinWidth(20f));
        NGUIEditorTools.DrawProperty("Layout Type", serializedObject, "mLayoutType", GUILayout.MinWidth(20f));
        NGUIEditorTools.DrawProperty("Max Count", serializedObject, "mMaxCount", GUILayout.MinWidth(20f));
        NGUIEditorTools.DrawProperty("Min Height", serializedObject, "mMinHeight", GUILayout.MinWidth(20f));
        base.DrawCustomProperties();

        StackLayout layout = target as StackLayout;

        layout.ResetLayout();
    }
Beispiel #9
0
 private void UpdateStack(int idx = 4)
 {
     for (int i = 0; i < mBtns.Length; i++)
     {
         mBtns[i].transform.parent = null;
     }
     mList.transform.parent = null;
     for (int i = 0; i < mBtns.Length; i++)
     {
         mBtns[i].transform.parent = mParent.transform;
         if (i == idx)
         {
             mList.transform.parent = mParent.transform;
         }
     }
     mStackLayout.ResetLayout();
     grid.ResetScrollViewPostionOffset();
 }
Beispiel #10
0
        private void LateUpdate()
        {
        #if !UNITY_EDITOR
            try
            {
        #endif

            if (isEnable)
            {
                LayerOut.ResetLayout();
                ResetPostion();
                isEnable = false;
            }

        #if !UNITY_EDITOR
        }

        catch (Exception ex)
        {
            Logger.Error(ex.ToString());
        }
        #endif
        }