Beispiel #1
0
    private void PrivateHideLayer(UILayer layer)
    {
#if USE_XLUA
        InvokeXLua("PrivateHideLayer", layer);
#else
        layer.DisableLayer();
        layer.BeforeHideLayer();
        layer.HideLayer();

        if (layer.allowDestroy)
        {
            layer.DestroyLayer();
            Destroy(layer.gameObject);
        }
        else
        {
            layer.ResetPosition();
            CacheLayer(layer);
        }
#endif
    }