Implementing shim and cache for theme awareness

Configured arrays of view engines cached for use in appropriate contexts
Adding current theme as dedicated property on work context
Current theme assigned by selecters, if null, as result begins executing
Distinction is made between deep and shallow view path locations

--HG--
branch : theming
This commit is contained in:
Louis DeJardin
2010-09-03 17:41:14 -07:00
parent 30fb9660a4
commit 2de2f685e9
20 changed files with 268 additions and 33 deletions

View File

@@ -1,187 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{63FBD4D9-E1DA-4A7B-AA6A-D6074FE50867}</ProjectGuid>
<ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Orchard.Blogs</RootNamespace>
<AssemblyName>Orchard.Blogs</AssemblyName>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<MvcBuildViews>false</MvcBuildViews>
<FileUpgradeFlags>
</FileUpgradeFlags>
<OldToolsVersion>3.5</OldToolsVersion>
<UpgradeBackupLocation />
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.ComponentModel.DataAnnotations">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Web.ApplicationServices" />
<Reference Include="System.Web.DynamicData" />
<Reference Include="System.Web.Entity" />
<Reference Include="System.Web.Extensions" />
<Reference Include="System.Drawing" />
<Reference Include="System.Web" />
<Reference Include="System.Web.Abstractions" />
<Reference Include="System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\lib\aspnetmvc\System.Web.Mvc.dll</HintPath>
</Reference>
<Reference Include="System.Web.Routing" />
<Reference Include="System.Xml" />
<Reference Include="System.Configuration" />
<Reference Include="System.Web.Services" />
<Reference Include="System.EnterpriseServices" />
<Reference Include="System.Web.Mobile" />
<Reference Include="System.Xml.Linq" />
</ItemGroup>
<ItemGroup>
<Compile Include="AdminMenu.cs" />
<Compile Include="Commands\BlogCommands.cs" />
<Compile Include="Controllers\BlogAdminController.cs" />
<Compile Include="DataMigrations\BlogsDataMigration.cs" />
<Compile Include="Drivers\BlogPartDriver.cs" />
<Compile Include="Controllers\BlogPostAdminController.cs" />
<Compile Include="Controllers\BlogPostController.cs" />
<Compile Include="Drivers\BlogPostPartDriver.cs" />
<Compile Include="Extensions\FeedManagerExtensions.cs" />
<Compile Include="Extensions\UrlHelperExtensions.cs" />
<Compile Include="Filters\ArchivesFilter.cs" />
<Compile Include="Models\ArchiveData.cs" />
<Compile Include="Handlers\BlogPartArchiveHandler.cs" />
<Compile Include="Models\BlogPartArchiveRecord.cs" />
<Compile Include="Permissions.cs" />
<Compile Include="Routing\IBlogSlugConstraint.cs" />
<Compile Include="Routing\IsArchiveConstraint.cs" />
<Compile Include="Routing\BlogSlugConstraint.cs" />
<Compile Include="Routing\BlogSlugConstraintUpdator.cs" />
<Compile Include="Services\BlogService.cs" />
<Compile Include="Controllers\BlogController.cs" />
<Compile Include="Models\BlogPart.cs" />
<Compile Include="Handlers\BlogPartHandler.cs" />
<Compile Include="Models\BlogPostPart.cs" />
<Compile Include="Handlers\BlogPostPartHandler.cs" />
<Compile Include="Models\BlogPartRecord.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Routes.cs" />
<Compile Include="Services\BlogPostService.cs" />
<Compile Include="Services\IBlogPostService.cs" />
<Compile Include="Services\IBlogService.cs" />
<Compile Include="Services\XmlRpcHandler.cs" />
<Compile Include="ViewModels\AdminBlogsViewModel.cs" />
<Compile Include="ViewModels\BlogArchivesViewModel.cs" />
<Compile Include="ViewModels\BlogPostArchiveViewModel.cs" />
<Compile Include="ViewModels\BlogViewModel.cs" />
<Compile Include="ViewModels\BlogPostViewModel.cs" />
<Compile Include="ViewModels\BlogPostEditViewModel.cs" />
<Compile Include="ViewModels\BlogsViewModel.cs" />
<Compile Include="ViewModels\BlogForAdminViewModel.cs" />
<Compile Include="ViewModels\CreateBlogPostViewModel.cs" />
<Compile Include="ViewModels\CreateBlogViewModel.cs" />
<Compile Include="ViewModels\BlogEditViewModel.cs" />
</ItemGroup>
<ItemGroup>
<Content Include="Content\Admin\images\draft.gif" />
<Content Include="Content\Admin\images\offline.gif" />
<Content Include="Content\Admin\images\online.gif" />
<Content Include="Content\Admin\images\published.gif" />
<Content Include="Content\Admin\images\scheduled.gif" />
<Content Include="Module.txt" />
<Content Include="Scripts\archives.js" />
<Content Include="Styles\admin.css" />
<Content Include="Styles\archives.css" />
<Content Include="Views\Archives.ascx" />
<Content Include="Views\BlogPostAdmin\Create.ascx" />
<Content Include="Views\BlogPostAdmin\Edit.ascx" />
<Content Include="Views\BlogPost\ListByArchive.ascx" />
<Content Include="Views\DisplayTemplates\Items\Blogs.Blog.DetailAdmin.ascx" />
<Content Include="Views\BlogAdmin\Item.ascx" />
<Content Include="Views\DisplayTemplates\Items\Blogs.Blog.SummaryAdmin.ascx" />
<Content Include="Views\Blog\List.ascx" />
<Content Include="Views\BlogAdmin\List.ascx" />
<Content Include="Views\DisplayTemplates\Items\Blogs.BlogPost.ascx" />
<Content Include="Views\DisplayTemplates\Items\Blogs.BlogPost.Summary.ascx" />
<Content Include="Views\DisplayTemplates\Items\Blogs.Blog.ascx" />
<Content Include="Views\DisplayTemplates\Parts\Blogs.Blog.Manage.ascx" />
<Content Include="Views\DisplayTemplates\Parts\Blogs.BlogPost.List.ascx" />
<Content Include="Views\DisplayTemplates\Parts\Blogs.BlogPost.List.DetailAdmin.ascx" />
<Content Include="Views\DisplayTemplates\Items\Blogs.Blog.Summary.ascx" />
<Content Include="Views\DisplayTemplates\Parts\Blogs.Blog.Description.ascx" />
<Content Include="Views\DisplayTemplates\Parts\Blogs.Blog.Metadata.ascx" />
<Content Include="Views\BlogPost\Item.ascx" />
<Content Include="Views\BlogAdmin\Create.ascx" />
<Content Include="Views\BlogAdmin\Edit.ascx" />
<Content Include="Views\Blog\Item.ascx" />
<Content Include="Views\EditorTemplates\Parts\Blogs.Blog.Fields.ascx" />
<Content Include="Views\EditorTemplates\Items\Blogs.Blog.ascx" />
<Content Include="Views\EditorTemplates\Items\Blogs.BlogPost.ascx" />
<Content Include="Web.config" />
<Content Include="Views\Web.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\Orchard\Orchard.Framework.csproj">
<Project>{2D1D92BB-4555-4CBE-8D0E-63563D6CE4C6}</Project>
<Name>Orchard.Framework</Name>
</ProjectReference>
<ProjectReference Include="..\..\Core\Orchard.Core.csproj">
<Project>{9916839C-39FC-4CEB-A5AF-89CA7E87119F}</Project>
<Name>Orchard.Core</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target> -->
<Target Name="AfterBuild" Condition="'$(MvcBuildViews)'=='true'">
<AspNetCompiler VirtualPath="temp" PhysicalPath="$(ProjectDir)" />
</Target>
<ProjectExtensions>
<VisualStudio>
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
<WebProjectProperties>
<UseIIS>False</UseIIS>
<AutoAssignPort>True</AutoAssignPort>
<DevelopmentServerPort>52475</DevelopmentServerPort>
<DevelopmentServerVPath>/</DevelopmentServerVPath>
<IISUrl>
</IISUrl>
<NTLMAuthentication>False</NTLMAuthentication>
<UseCustomServer>True</UseCustomServer>
<CustomServerUrl>http://orchard.codeplex.com</CustomServerUrl>
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
</WebProjectProperties>
</FlavorProperties>
</VisualStudio>
</ProjectExtensions>
</Project>