Changed the profiler over to use resolvers again. We no longer will call MiniProfiler directly.

Added an HtmlHelper extension which is used to render the profiler html output.
Added an HtmlHelper property to the new base page too.
This commit is contained in:
Shannon Deminick
2013-05-13 20:10:28 -10:00
parent 922ebe5411
commit b6f52bf782
19 changed files with 333 additions and 331 deletions

View File

@@ -1,37 +1,37 @@
//using Umbraco.Core.ObjectResolution;
using Umbraco.Core.ObjectResolution;
//namespace Umbraco.Core.Profiling
//{
// /// <summary>
// /// A resolver exposing the current profiler
// /// </summary>
// public class ProfilerResolver : SingleObjectResolverBase<ProfilerResolver, IProfiler>
// {
// /// <summary>
// /// Constructor
// /// </summary>
// /// <param name="profiler"></param>
// public ProfilerResolver(IProfiler profiler)
// : base(profiler)
// {
// }
namespace Umbraco.Core.Profiling
{
/// <summary>
/// A resolver exposing the current profiler
/// </summary>
internal class ProfilerResolver : SingleObjectResolverBase<ProfilerResolver, IProfiler>
{
/// <summary>
/// Constructor
/// </summary>
/// <param name="profiler"></param>
public ProfilerResolver(IProfiler profiler)
: base(profiler)
{
// /// <summary>
// /// Method allowing to change the profiler during startup
// /// </summary>
// /// <param name="profiler"></param>
// internal void SetProfiler(IProfiler profiler)
// {
// Value = profiler;
// }
}
// /// <summary>
// /// Gets the current profiler
// /// </summary>
// public IProfiler Profiler
// {
// get { return Value; }
// }
// }
//}
/// <summary>
/// Method allowing to change the profiler during startup
/// </summary>
/// <param name="profiler"></param>
internal void SetProfiler(IProfiler profiler)
{
Value = profiler;
}
/// <summary>
/// Gets the current profiler
/// </summary>
public IProfiler Profiler
{
get { return Value; }
}
}
}