aboutsummaryrefslogtreecommitdiffstats
path: root/ui/selectmenu.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui/selectmenu.js')
-rw-r--r--ui/selectmenu.js26
1 files changed, 18 insertions, 8 deletions
diff --git a/ui/selectmenu.js b/ui/selectmenu.js
index 66398a6e3..2a89d9dd0 100644
--- a/ui/selectmenu.js
+++ b/ui/selectmenu.js
@@ -7,14 +7,24 @@
* http://jquery.org/license
*
* http://api.jqueryui.com/selectmenu
- *
- * Depends:
- * jquery.ui.core.js
- * jquery.ui.widget.js
- * jquery.ui.position.js
- * jquery.ui.menu.js
*/
-(function( $, undefined ) {
+(function( factory ) {
+ if ( typeof define === "function" && define.amd ) {
+
+ // AMD. Register as an anonymous module.
+ define([
+ "jquery",
+ "./core",
+ "./widget",
+ "./position",
+ "./menu"
+ ], factory );
+ } else {
+
+ // Browser globals
+ factory( jQuery );
+ }
+}(function( $ ) {
return $.widget( "ui.selectmenu", {
version: "@VERSION",
@@ -533,4 +543,4 @@ return $.widget( "ui.selectmenu", {
}
});
-}( jQuery ));
+}));