summaryrefslogtreecommitdiffstats
path: root/tools/droiddoc
diff options
context:
space:
mode:
authorsmain@google.com <smain@google.com>2014-06-13 15:06:23 -0700
committerScott Main <smain@google.com>2014-06-13 22:10:37 +0000
commit6040ffa1e8311278c9ef72a0c52ec4e048eb5006 (patch)
tree6555983374762d53d2f10310410dfcb4d6bb0fff /tools/droiddoc
parenta6913b5c22b8eac6b5b62099c3a848a1e712d675 (diff)
downloadbuild-6040ffa1e8311278c9ef72a0c52ec4e048eb5006.zip
build-6040ffa1e8311278c9ef72a0c52ec4e048eb5006.tar.gz
build-6040ffa1e8311278c9ef72a0c52ec4e048eb5006.tar.bz2
add About secondary nav bar
and delete the Wear custom header Change-Id: If7ac93556586d369a2dbf7e1fc4044473ace7bc9
Diffstat (limited to 'tools/droiddoc')
-rw-r--r--tools/droiddoc/templates-sdk/assets/css/default.css3
-rw-r--r--tools/droiddoc/templates-sdk/assets/js/docs.js12
-rw-r--r--tools/droiddoc/templates-sdk/components/masthead.cs74
-rw-r--r--tools/droiddoc/templates-sdk/docpage.cs2
4 files changed, 40 insertions, 51 deletions
diff --git a/tools/droiddoc/templates-sdk/assets/css/default.css b/tools/droiddoc/templates-sdk/assets/css/default.css
index 0a5174c..9bfe3d5 100644
--- a/tools/droiddoc/templates-sdk/assets/css/default.css
+++ b/tools/droiddoc/templates-sdk/assets/css/default.css
@@ -1526,6 +1526,9 @@ Header, Login, Nav-X, Search
color: #333;
font-size: 16px;
}
+.about a.selected {
+ color: #9933CC;
+}
.design a.selected {
color: #33b5e5;
}
diff --git a/tools/droiddoc/templates-sdk/assets/js/docs.js b/tools/droiddoc/templates-sdk/assets/js/docs.js
index ffd9eef..4b5dee2 100644
--- a/tools/droiddoc/templates-sdk/assets/js/docs.js
+++ b/tools/droiddoc/templates-sdk/assets/js/docs.js
@@ -173,6 +173,18 @@ $(document).ready(function() {
$("#header li.design a").addClass("selected");
$("#sticky-header").addClass("design");
+ // highlight About tabs
+ } else if ($("body").hasClass("about")) {
+ var rootDir = pagePathOriginal.substring(1,pagePathOriginal.indexOf('/', 1));
+ if (rootDir == "about") {
+ $("#nav-x li.about a").addClass("selected");
+ } else if (rootDir == "wear") {
+ $("#nav-x li.wear a").addClass("selected");
+ } else if (rootDir == "tv") {
+ $("#nav-x li.tv a").addClass("selected");
+ } else if (rootDir == "auto") {
+ $("#nav-x li.auto a").addClass("selected");
+ }
// highlight Develop tab
} else if ($("body").hasClass("develop") || $("body").hasClass("google")) {
$("#header li.develop a").addClass("selected");
diff --git a/tools/droiddoc/templates-sdk/components/masthead.cs b/tools/droiddoc/templates-sdk/components/masthead.cs
index d0ff64d..908ed25 100644
--- a/tools/droiddoc/templates-sdk/components/masthead.cs
+++ b/tools/droiddoc/templates-sdk/components/masthead.cs
@@ -1,7 +1,4 @@
<?cs def:custom_masthead() ?>
-<?cs if:wear ?>
- <?cs call:wear_masthead() ?>
-<?cs else ?>
<a name="top"></a>
<?cs if:!devsite ?><?cs # leave out the global header for devsite; it is in devsite template ?>
<!-- Header -->
@@ -126,7 +123,27 @@
</div><!-- end header-wrap.wrap -->
</div><!-- end header -->
- <?cs if:training || guide || reference || tools || develop || google || samples ?>
+ <?cs if:about || wear || tv || auto ?>
+ <!-- Secondary x-nav -->
+ <div id="nav-x">
+ <div class="wrap">
+ <ul class="nav-x col-9 about" style="width:100%">
+ <li class="about"><a href="<?cs var:toroot ?>about/index.html"
+ >About</a></li>
+ <li class="wear"><a href="<?cs var:toroot ?>wear/index.html"
+ >Wear</a></li>
+ <li class="tv"><a href="<?cs var:toroot ?>tv/index.html"
+ >TV</a></li>
+ <li class="auto"><a href="<?cs var:toroot ?>auto/index.html"
+ >Auto</a></li>
+ </ul>
+ </div>
+ </div>
+ <!-- /Sendondary x-nav ABOUT -->
+
+
+
+ <?cs elif:training || guide || reference || tools || develop || google || samples ?>
<!-- Secondary x-nav -->
<div id="nav-x">
<div class="wrap">
@@ -174,7 +191,7 @@
</ul>
</div>
</div>
- <!-- /Sendondary x-nav -->
+ <!-- /Sendondary x-nav DEVELOP -->
<?cs elif:distribute || googleplay || essentials || users || engage || monetize || disttools || stories ?>
<!-- Secondary distribute x-nav -->
@@ -202,6 +219,7 @@
<a href="https://play.google.com/apps/publish/" class="developer-console-btn">Developer Console</a>
</div> <!-- /Secondary distribute x-nav -->
</div>
+ <!-- /Sendondary x-nav DISTRIBUTE -->
<?cs /if ?>
<div id="searchResults" class="wrap" style="display:none;">
@@ -222,49 +240,5 @@
</div>
</div>
-<?cs /if ?><?cs # end if/else !devsite ?>
-<?cs /if ?><?cs # end if/else wear ?><?cs
-/def ?>
-
-<?cs def:wear_masthead() ?>
-<a name="top"></a>
-
-<!-- Header -->
-<div id="header-wrapper">
- <div id="header">
- <div class="wrap" id="header-wrap">
- <div class="col_3 logo wear-logo">
- <a href="<?cs var:toroot ?>wear/index.html">
- <img src="<?cs var:toroot ?>wear/images/android-wear.png" height="16" alt="Android Wear" />
- </a>
- </div>
- <div class="col-8" style="margin:0"><h1 style="margin:1px 0 0 20px;padding:0;line-height:16px;
-color:#666;font-weight:100;font-size:24px;">Developer Preview</h1></div>
-
- <?cs # ADD SEARCH AND MENU ?>
- <?cs call:header_search_widget() ?>
-
- </div><!-- end header-wrap -->
- </div><!-- /Header -->
-
-
- <div id="searchResults" class="wrap" style="display:none;">
- <h2 id="searchTitle">Results</h2>
- <div id="leftSearchControl" class="search-control">Loading...</div>
- </div>
-</div> <!--end header-wrapper -->
-
-<div id="sticky-header">
- <div>
- <a class="logo" href="#top"></a>
- <a class="top" href="#top"></a>
- <ul class="breadcrumb">
- <?cs # More <li> elements added here with javascript ?>
- <?cs if:!section.landing ?><li class="current"><?cs var:page.title ?></li><?cs
- /if ?>
- </ul>
- </div>
-</div>
-
- <?cs
+<?cs /if ?><?cs # end if/else !devsite ?><?cs
/def ?>
diff --git a/tools/droiddoc/templates-sdk/docpage.cs b/tools/droiddoc/templates-sdk/docpage.cs
index 3c99f16..f6e1cac 100644
--- a/tools/droiddoc/templates-sdk/docpage.cs
+++ b/tools/droiddoc/templates-sdk/docpage.cs
@@ -18,7 +18,7 @@ if:(google || reference.gms || reference.gcm) ?>google<?cs /if ?><?cs
if:monetize ?> monetize<?cs /if ?><?cs
if:disttools ?> disttools<?cs /if ?><?cs
if:stories ?> stories<?cs /if ?><?cs
- elif:about ?>about<?cs
+ elif:(about||wear||tv||auto) ?>about<?cs
elif:design ?>design<?cs
/if ?><?cs
if:page.trainingcourse ?> trainingcourse<?cs