• download
  • documentation
  • forums
  • demo
  • contact
  • blog

meteora

javascript widgets

Documentation

  • Autocomplete
  • Bubble
  • Calendar
  • Carousel
  • Datagrid
  • Dialog
  • Editor
  • Effect
  • Filebrowser
  • Form
  • Jsonrpc
  • Menu
  • Notebook
  • Picbox
  • Popup
  • Searchlist
  • Selection
  • Spinbutton
  • Tablesort
  • Toolbox
  • Treeview

Widget demo

HTML source

<div id="menu-demo-div"></div>

Javascript source

Meteora.uses('Meteora.Menu');
Meteora.onStart(
  function () {
    new Menu(
      'menu-demo-div',
      [
        {
          'label': 'File',
          'onClick': function() {
            alert('You have clicked on "File".');
          },
          'icon': 'go-next.png',
          'items': [
            {
              'label': 'New...',
              'icon': 'document-new.png'
            },
            {
              'label': 'Open...',
              'icon': 'document-open.png'
            },
            {
              'label': 'Print',
              'icon': 'document-print-preview.png'
            },
          ]
        },
        {
          'label': 'Edit',
          'icon': 'edit-copy.png',
          'items': [
            {
              'label': 'Preferences',
              'onClick': function() {
                alert('You have clicked on "Preferences"');
              }
            }
          ]
        },
        {
          'label': 'View',
          'icon': 'edit-find.png',
          'items': [
            {
              'label': 'Toolbars',
              'items': [
                {
                  'label': 'Toolbar 1'
                },
                {
                  'label': 'Toolbar 2',
                  'items': [
                    {
                      'label': 'test'
                    },
                    {
                      'label': 'test',
                      'items': [
                        {
                          'label': 'test x'
                        }
                      ]
                    },
                    {
                      'label': 'test'
                    }
                  ]
                }
              ]
            },
            {
              'label': 'Sidebar',
              'items': [
                {
                  'label': 'Foo'
                }
              ]
            }
          ]
        }
      ],
      {
        iconDir: '/media/demo'
      }
    );
  }
);

Documentation

If you're looking for more documentation about this widget, you may want to read Meteora.Menu documentation

Copyright © 2007-2009 Astrata Software.