kkallio@6: open Navbar kkallio@6: open PopupNav kkallio@6: kkallio@6: val testNav = navAdd (mkNavItem "item 2" (bless "http://item2.org")) kkallio@6: (navAdd (mkNavItem "item 1" (bless "http://item1.org")) kkallio@6: emptyNavBar) kkallio@6: kkallio@6: val testNav' = navAdd (mkNavItem "item 3" (bless "http://item3.org")) kkallio@6: testNav kkallio@6: kkallio@7: val otherFormat = {FormatMenu = fn ctl menu =>

A Custom {ctl} Format

{menu}
, kkallio@7: WrapMenu = fn menu =>
, kkallio@6: OpenCtl = fn behaviour => View, kkallio@6: CloseCtl = fn behaviour => Hide} kkallio@6: kkallio@6: kkallio@6: fun main () = kkallio@6: kkallio@6: defaultFormatPopUp <- create defaultFormat testNav'; kkallio@6: otherFormatPopUp <- create otherFormat testNav'; kkallio@6: kkallio@6: return kkallio@6: kkallio@6: Navbar Based Popup Navigation. kkallio@6: kkallio@6: kkallio@6:

Example of using Navbar to build a widget.

kkallio@6:

kkallio@6: This is a widget which generates a popup list kkallio@6: of links. kkallio@6:

kkallio@6:

Example of the default format.

kkallio@6:

kkallio@6: {render defaultFormatPopUp} kkallio@6:

kkallio@6:

Example of another format.

kkallio@6:

kkallio@6: {render otherFormatPopUp} kkallio@6:

kkallio@6: kkallio@6: