summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrédéric Péters <fpeters@entrouvert.com>2011-11-29 14:47:12 (GMT)
committerFrédéric Péters <fpeters@entrouvert.com>2011-11-29 14:47:12 (GMT)
commitf8856f99304a5738ca9bebab462d1b277049ab63 (patch)
treea83bd23579c144936921ad346b00e9a1da6d5029
parentc41cec28e6c1ae84e5c78e27dfc8825f3fe669e7 (diff)
downloadtabellio.webviews-f8856f99304a5738ca9bebab462d1b277049ab63.zip
tabellio.webviews-f8856f99304a5738ca9bebab462d1b277049ab63.tar.gz
tabellio.webviews-f8856f99304a5738ca9bebab462d1b277049ab63.tar.bz2
magic down menu
-rw-r--r--tabellio/webviews/pcfnav.pt15
1 files changed, 14 insertions, 1 deletions
diff --git a/tabellio/webviews/pcfnav.pt b/tabellio/webviews/pcfnav.pt
index 2d52422..7dd5f78 100644
--- a/tabellio/webviews/pcfnav.pt
+++ b/tabellio/webviews/pcfnav.pt
@@ -1,5 +1,5 @@
<tal:block i18n:domain="plone">
-<dl class="portlet portletNavigationTree"
+<dl class="portlet portletNavigationTree" id="pcf-top-nav"
tal:define="root view/navigation_root">
<dt class="portletHeader"
@@ -38,5 +38,18 @@
<span class="portletBottomLeft"></span>
<span class="portletBottomRight"></span>
</dd>
+
+ <script type="text/javascript">
+(function($) {
+ current_section = $('#menu .selected').offset();
+ $('#menu .selected').prepend('<span id="navmarker"'+'><'+'/span>');
+ $('#navmarker').click(function() { $('#pcf-top-nav').toggle(); });
+ console.log(current_section);
+ $('#pcf-top-nav').hide().css('position', 'absolute'
+ ).css('top', current_section.top+40
+ ).css('left', current_section.left-50);
+})(jQuery);
+
+ </script>
</dl>
</tal:block>