Inheritance: IView, IDisposable
        private ViewEngineResult CreateNestedView(
            ViewEngineResult result,
            ControllerContext controllerContext)
        {
            if (result.View == null)
                return result;

            var parentContainer = controllerContext.HttpContext.GetContainer();

            var nestedContainer = parentContainer.GetNestedContainer();

            var webFormView = (WebFormView)result.View;

            var wrappedView = new WrappedView(webFormView, nestedContainer);

            var newResult = new ViewEngineResult(wrappedView, this);

            return newResult;
        }
Ejemplo n.º 2
0
        private ViewEngineResult CreateNestedView(
            ViewEngineResult result,
            ControllerContext controllerContext)
        {
            if (result.View == null)
            {
                return(result);
            }

            var parentContainer = controllerContext.HttpContext.GetContainer();

            var nestedContainer = parentContainer.GetNestedContainer();

            var webFormView = (WebFormView)result.View;

            var wrappedView = new WrappedView(webFormView, nestedContainer);

            var newResult = new ViewEngineResult(wrappedView, this);

            return(newResult);
        }