Permalink
Browse files

Widgets: Remove mobile base widget and extend $.widget instead. Fixes #…

  • Loading branch information...
arschmitz committed Jul 4, 2013
1 parent 05d100d commit 245e3d1d0e9f0ae5f546cf051da0b779c474e4a2
@@ -101,7 +101,7 @@
});
//h2 widget
$( document ).on( "mobileinit", function(){
$.widget( "mobile.h2linker", $.mobile.widget, {
$.widget( "mobile.h2linker", {
options:{
initSelector: ":jqmData(quicklinks='true')"
},
@@ -8,7 +8,7 @@ define( [ "jquery", "./jquery.mobile.ns", "jquery.ui.widget" ], function( jQuery
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.widget", {
$.extend( $.Widget.prototype, {
_getCreateOptions: function() {
var elem = this.element,
@@ -57,7 +57,7 @@ $.widget( "mobile.widget", {
throw "Widget [" + this.widgetName + "]: " + msg;
}
});
$.mobile.widget = $.Widget;
})( jQuery );
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
});
@@ -15,7 +15,7 @@ define( [
var getAttr = $.mobile.getAttribute;
$.widget( "mobile.collapsible", $.mobile.widget, {
$.widget( "mobile.collapsible", {
options: {
expandCueText: " click to expand contents",
collapseCueText: " click to collapse contents",
@@ -9,7 +9,7 @@ define( [ "jquery", "../jquery.mobile.widget", "./collapsible", "./addFirstLastC
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.collapsibleset", $.mobile.widget, $.extend( {
$.widget( "mobile.collapsibleset", $.extend( {
_create: function() {
var $el = this.element,
o = this.options,
@@ -12,7 +12,7 @@ define( [ "jquery",
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.controlgroup", $.mobile.widget, $.extend( {
$.widget( "mobile.controlgroup", $.extend( {
options: {
theme: null,
shadow: false,
View
@@ -9,7 +9,7 @@ define( [ "jquery", "../jquery.mobile.widget", "./page", "../jquery.mobile.navig
//>>excludeEnd("jqmBuildExclude");
(function( $, window, undefined ) {
$.widget( "mobile.dialog", $.mobile.widget, $.extend( {
$.widget( "mobile.dialog", $.extend( {
options: {
closeBtn: "left", /* Accepts left, right and none */
closeBtnText: "Close",
@@ -9,7 +9,7 @@ define( [ "jquery", "../../jquery.mobile.widget", "../../jquery.mobile.registry"
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.button", $.mobile.widget, {
$.widget( "mobile.button", {
options: {
theme: null,
icon: null,
@@ -17,7 +17,7 @@ define( [ "jquery",
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.checkboxradio", $.mobile.widget, $.extend( {
$.widget( "mobile.checkboxradio", $.extend( {
options: {
theme: null,
mini: false
@@ -14,7 +14,7 @@ define( [ "jquery",
"./slider" ], function( jQuery ) {
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.rangeslider", $.mobile.widget, $.extend( {
$.widget( "mobile.rangeslider", $.extend( {
options: {
theme: null,
@@ -9,7 +9,7 @@ define( [ "jquery", "../../jquery.mobile.core", "../../jquery.mobile.widget", ".
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.selectmenu", $.mobile.widget, $.extend( {
$.widget( "mobile.selectmenu", $.extend( {
options: {
theme: null,
disabled: false,
@@ -14,7 +14,7 @@ define( [ "jquery",
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.slider", $.mobile.widget, $.extend( {
$.widget( "mobile.slider", $.extend( {
widgetEventPrefix: "slide",
options: {
@@ -9,7 +9,7 @@ define( [ "jquery", "../../jquery.mobile.core", "../../jquery.mobile.widget", ".
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.textinput", $.mobile.widget, {
$.widget( "mobile.textinput", {
options: {
theme: null,
corners: true,
View
@@ -11,7 +11,7 @@ define( [ "jquery", "../jquery.mobile.widget", "./page", "./addFirstLastClasses"
var getAttr = $.mobile.getAttribute;
$.widget( "mobile.listview", $.mobile.widget, $.extend( {
$.widget( "mobile.listview", $.extend( {
options: {
theme: null,
View
@@ -10,7 +10,7 @@ define( [ "jquery", "../jquery.mobile.widget", "../jquery.mobile.grid", "../jque
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.navbar", $.mobile.widget, {
$.widget( "mobile.navbar", {
options: {
iconpos: "top",
grid: null
View
@@ -7,7 +7,7 @@ define( [ "jquery", "../jquery.mobile.widget", "../jquery.mobile.core", "../jque
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.page", $.mobile.widget, {
$.widget( "mobile.page", {
options: {
theme: "a",
domCache: false,
@@ -55,7 +55,6 @@ $.widget( "mobile.page", $.mobile.widget, {
},
_setOptions: function( o ) {
if( o.theme !== undefined ) {
this.element.removeClass( "ui-body-" + this.options.theme ).addClass( "ui-body-" + o.theme );
}
View
@@ -9,7 +9,7 @@ define( [ "jquery", "../jquery.mobile.widget", "./page", "../jquery.mobile.regis
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.panel", $.mobile.widget, {
$.widget( "mobile.panel", {
options: {
classes: {
panel: "ui-panel",
View
@@ -52,7 +52,7 @@ function windowCoords() {
};
}
$.widget( "mobile.popup", $.mobile.widget, {
$.widget( "mobile.popup", {
options: {
theme: null,
overlayTheme: null,
View
@@ -9,7 +9,7 @@ define( [ "jquery", "../jquery.mobile.widget", "./page", "../jquery.mobile.regis
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget( "mobile.table", $.mobile.widget, {
$.widget( "mobile.table", {
options: {
classes: {
table: "ui-table"
View
@@ -8,11 +8,9 @@ define( [ "jquery", "../jquery.mobile.widget", "../jquery.mobile.core","./jquery
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {
$.widget("mobile.tabs", $.mobile.widget, $.ui.tabs.prototype);
$.ui.tabs.initSelector = ":jqmData(role='tabs'), :jqmData(content='tabs')";
$.mobile.tabs.initSelector = ":jqmData(role='tabs'), :jqmData(content='tabs')";
$.mobile._enhancer.add( "mobile.tabs" );
$.mobile._enhancer.add( "ui.tabs" );
})( jQuery );
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
View
@@ -10,7 +10,7 @@ define( [ "jquery", "../jquery.mobile.widget", "../jquery.mobile.core", "../jque
(function( $, undefined ) {
$.widget( "mobile.toolbar", $.mobile.widget, {
$.widget( "mobile.toolbar", {
options: {
theme: null,
addBackBtn: false,

0 comments on commit 245e3d1

Please sign in to comment.