123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112 |
- <!DOCTYPE html>
- <html>
- <head>
- <link rel="stylesheet" href="../../../themes/themeroller/default-theme/ui.all.css" type="text/css" media="screen" />
- <link rel="stylesheet" href="../../../themes/nokia/ext-theme/default/360x640/custom.css" type="text/css" media="screen" />
- <script src="../../../lib/jquery/jquery.js" type="text/javascript" charset="utf-8"></script>
- <script src="../../../src/defaults.js" type="text/javascript" charset="utf-8"></script>
- <script src="../../../src/core.js" type="text/javascript" charset="utf-8"></script>
-
- <style type="text/css" media="screen">
- body {
- font-size: 14px;
- padding: 10px;
- font-family: "Trebuchet MS", "Helvetica", "Arial", "Verdana", "sans-serif";
- max-width: 640px;
- }
- p {
- margin: 30px 10px;
- }
- </style>
-
- </head>
- <body>
-
- <div id="dropdown"></div>
-
- <p>Testing text</p>
- <script type="text/javascript" charset="utf-8">
-
- if (window.widget) {
- widget.setNavigationEnabled(false);
- }
- var init = function() {
-
- window.dropdown = new Nokia.DropDown({
- element: '#dropdown',
- show: function() {
- console.log("show");
- },
- hide: function() {
- console.log("hide");
- },
- items: [
- {
- label: "First option",
- value: 'some value',
- select: function(item, event) {
- console.log('Drop Down Clicked on: ' + item.label);
- }
- },
- {
- label: "Second option",
- value: 'some value',
- select: function(item, event) {
- console.log('Drop Down Clicked on: ' + item.label);
- }
- },
- {
- label: "Third option",
- value: 'some value',
- select: function(item, event) {
- console.log('Drop Down Clicked on: ' + item.label);
- }
- },
- {
- label: "Fourth option",
- value: 'some value',
- select: function(item, event) {
- console.log('Drop Down Clicked on: ' + item.label, item.value);
- }
- },
- {
- label: "Fifth option",
- value: 'some value',
- select: function(item, event) {
- console.log('Drop Down Clicked on: ' + item.label);
- }
- }
- ]
- });
-
- /*
- * Hide splash when its all done.
- */
-
- Nokia.hideSplash();
- };
-
- /*
- * Show splash while loading components.
- */
-
- Nokia.showSplash('<span>loading</span>');
-
- Nokia.use('dropdown', init);
- </script>
- </body>
- </html>
|