Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4950)

Unified Diff: chrome/common/extensions/docs/server2/template_data_source.py

Issue 10750017: Extensions Docs Server: Intro data source (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/docs/server2/template_data_source.py
diff --git a/chrome/common/extensions/docs/server2/template_data_source.py b/chrome/common/extensions/docs/server2/template_data_source.py
index ef0219f0f94638c736687d4b502be5f394640441..760f7c903c7c1c429f38f0359695d273b05c0fb4 100644
--- a/chrome/common/extensions/docs/server2/template_data_source.py
+++ b/chrome/common/extensions/docs/server2/template_data_source.py
@@ -10,11 +10,17 @@ class TemplateDataSource(object):
"""This class fetches and compiles templates using the fetcher passed in with
|cache_builder|.
"""
- def __init__(self, branch, api_data_source, cache_builder, base_paths):
+ def __init__(self,
+ branch,
+ api_data_source,
+ intro_data_source,
+ cache_builder,
+ base_paths):
self._branch_info = self._MakeBranchDict(branch)
self._static_resources = ((('/' + branch) if branch != 'local' else '') +
'/static')
self._api_data_source = api_data_source
+ self._intro_data_source = intro_data_source
self._cache = cache_builder.build(self._LoadTemplate)
self._base_paths = base_paths
@@ -45,6 +51,7 @@ class TemplateDataSource(object):
return template.render({
'apis': self._api_data_source,
'branchInfo': self._branch_info,
+ 'intros': self._intro_data_source,
'partials': self,
'static': self._static_resources
}).text

Powered by Google App Engine
This is Rietveld 408576698