Since widgets are dynamically added, if you want jquery mobile styles to be applied, you have to call trigger('create') for the widget container.
This can be placed inside the RenderView function after the var container = $(cuid);:
container.trigger('create');
It is recommended to call this only once, so add a "Initialized : false" field next to the GroupName, Description, etc..., fields.
So the code should look like this:
[{
Name: "My Widget",
Author: "Foo Bar",
Version: "2014-05-01",
GroupName : '',
IconImage : 'pages/control/widgets/homegenie/generic/images/mydefaultimg.png',
Description : '',
Initialized : false,
RenderView: function (cuid, module) {
var _this = this;
var container = $(cuid);
var widget = container.find('[data-ui-field=widget]');
var controlpopup = widget.data('ControlPopUp');
// apply jquery mobile styles
if (!this.Initialized)
{
container.trigger('create');
this.Initialized = true;
}
// ...
}
}]
Cheers,
g.