[PATCH] Have a separate <div> for the navigation bar

Paul Vriens Paul.Vriens.Wine at gmail.com
Wed Aug 5 01:09:00 CDT 2009


---
 transl/php/index.php    |    7 +++++++
 transl/php/lang.php     |    8 +++++++-
 transl/php/lib.php      |    8 ++++++--
 transl/php/resfile.php  |    9 ++++++++-
 transl/php/resource.php |   12 ++++++++++--
 transl/php/style.css    |    8 ++++++++
 6 files changed, 46 insertions(+), 6 deletions(-)

diff --git a/transl/php/index.php b/transl/php/index.php
index 77c3e4b..2b3fafb 100644
--- a/transl/php/index.php
+++ b/transl/php/index.php
@@ -27,6 +27,13 @@ while ($line = fgets($summary, 1024))
     <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
     <title>Wine translation statistics <?php echo $TITLE_APPENDIX ?></title>
 </head>
+
+<div class="navbar">
+<?php
+dump_menu_root(FALSE);
+?>
+</div>
+
 <div class="main">
 <h1>Wine translation statistics <?php echo $TITLE_APPENDIX ?></h1>
 <div class="contents">
diff --git a/transl/php/lang.php b/transl/php/lang.php
index 304783d..e3a71f7 100644
--- a/transl/php/lang.php
+++ b/transl/php/lang.php
@@ -88,7 +88,13 @@ function dump_table($table)
     <title><?php echo get_lang_name($lang) ?> language - Wine translations</title>
 </head>
 
-<p><?php dump_menu_root() ?> &gt; <?php dump_menu_lang($lang, FALSE)?> </p>
+<div class="navbar">
+<?php
+dump_menu_root(); echo " &gt; ";
+dump_menu_lang($lang, FALSE);
+?>
+</div>
+
 <div class="main">
 <h1><?php echo "Language: ".get_lang_name($lang) ?></h1>
 
diff --git a/transl/php/lib.php b/transl/php/lib.php
index 8d23291..246c2a7 100644
--- a/transl/php/lib.php
+++ b/transl/php/lib.php
@@ -241,9 +241,13 @@ function gen_resource_a($lang, $resfile, $type, $id, $compare=FALSE)
            "&amp;type=".urlencode($type)."&amp;id=".urlencode($id)."$extra\">";
 }
 
-function dump_menu_root()
+function dump_menu_root($link = TRUE)
 {
-    echo "<a href=\"index.php\">Wine translations</a>";
+    if ($link)
+        echo "<a href=\"index.php\">";
+    echo "Wine translations";
+    if ($link)
+        echo "</a>";
 }
 
 function dump_menu_lang($lang, $link = TRUE)
diff --git a/transl/php/resfile.php b/transl/php/resfile.php
index 4fcd2d7..280f4b0 100644
--- a/transl/php/resfile.php
+++ b/transl/php/resfile.php
@@ -15,7 +15,14 @@ $msgs = array();
     <title>Module <?php echo $resfile?> - Wine translations</title>
 </head>
 
-<?php dump_menu_root() ?> &gt <?php dump_menu_lang($lang) ?> &gt <?php dump_menu_resfile($lang, $resfile, FALSE) ?>
+<div class="navbar">
+<?php
+dump_menu_root(); echo " &gt; ";
+dump_menu_lang($lang); echo " &gt; ";
+dump_menu_resfile($lang, $resfile, FALSE);
+?>
+</div>
+
 <div class="main">
 <h1>Module <?php echo $resfile?></h1>
 
diff --git a/transl/php/resource.php b/transl/php/resource.php
index db9e3ac..3474e42 100644
--- a/transl/php/resource.php
+++ b/transl/php/resource.php
@@ -18,8 +18,16 @@ $compare = isset($_REQUEST['compare']);
     <title><?php echo get_resource_name($type, $id) ?> from <?php echo $resfile?> - Wine translation</title>
 </head>
 <body>
-<?php dump_menu_root() ?> &gt <?php dump_menu_lang($lang) ?> &gt <?php dump_menu_resfile($lang, $resfile) ?> &gt
-<?php dump_menu_resource($lang, $resfile, $type, $id) ?>
+
+<div class="navbar">
+<?php
+dump_menu_root(); echo " &gt; ";
+dump_menu_lang($lang); echo " &gt; ";
+dump_menu_resfile($lang, $resfile); echo " &gt; ";
+dump_menu_resource($lang, $resfile, $type, $id);
+?>
+</div>
+
 <div class="main">
 <h1>Dump of <?php echo get_resource_name($type, $id) ?></h1>
 
diff --git a/transl/php/style.css b/transl/php/style.css
index b963c06..557de2c 100644
--- a/transl/php/style.css
+++ b/transl/php/style.css
@@ -31,6 +31,14 @@ h1 :link {
     color: #ffe0e0;
 }
 
+div.navbar {
+    background-color: #E2E2E2;
+    margin: 10px 0;
+    padding: 0;
+    text-align: left;
+    width: 100%;
+}
+
 div.main {
     margin: 10px 0 0 0;
     background-color: white;
-- 
1.6.0.6


--------------070603050004080300000303--



More information about the wine-patches mailing list