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

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

Issue 103413002: Docserver: Include <h4> tags in the table of contents, it's needed for the API (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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/server_instance.py
diff --git a/chrome/common/extensions/docs/server2/server_instance.py b/chrome/common/extensions/docs/server2/server_instance.py
index b313bd15a03608fc0ac2c53feb240343b1e49b60..5179e1cbdc13484d14351e5f290a5d12866a4637 100644
--- a/chrome/common/extensions/docs/server2/server_instance.py
+++ b/chrome/common/extensions/docs/server2/server_instance.py
@@ -67,10 +67,6 @@ class ServerInstance(object):
assert base_path.startswith('/') and base_path.endswith('/')
self.base_path = base_path
- self.document_renderer = DocumentRenderer(TableOfContentsRenderer(
- host_fs_at_trunk,
- compiled_fs_factory))
-
self.host_file_system_iterator = HostFileSystemIterator(
host_file_system_provider,
branch_utility)
@@ -153,6 +149,14 @@ class ServerInstance(object):
# the entire ServerInstance doesn't need to be passed in here.
self.template_renderer = TemplateRenderer(self)
+ # TODO(kalman): It may be better for |document_renderer| to construct a
+ # TemplateDataSource itself rather than depending on template_renderer, but
+ # for that the above todo should be addressed.
+ self.document_renderer = DocumentRenderer(TableOfContentsRenderer(
+ host_fs_at_trunk,
+ compiled_fs_factory,
+ self.template_renderer))
+
@staticmethod
def ForTest(file_system=None, file_system_provider=None, base_path='/'):
object_store_creator = ObjectStoreCreator.ForTest()

Powered by Google App Engine
This is Rietveld 408576698