Questions tagged [jquery-ui-widget]

35 questions
5
votes
2 answers

Is there an alternative for jQuery UI's widgets?

I'm making a calendar for jquery mobile, I'm using the jquery weekcalendar (jQ wC), but the problem is, that jQ wC is using jquery UI, and this is in conflict with jquery mobile. For this reason, I have removed everything UI related out of the jQ…
4
votes
2 answers

Can a google map be removed from an element?

I've been messing around with jQuery-UI's widget factory to create a google map widget. The widget factory includes pre-built destroy capabilities to remove a widget from an element. I'm interested to know whether there's a way to detach the…
zzzzBov
  • 174,988
  • 54
  • 320
  • 367
4
votes
1 answer

How do subclass a widget

jQuery UI 1.8 added the ability to extend a widget using code like this: $.widget("my.weirdbutton", $.ui.button, { }); Now I can create a weirdbutton and it works a lot like a button: $("#myButton").weirdbutton(); However, only weirdbutton events…
itsadok
  • 28,822
  • 30
  • 126
  • 171
3
votes
5 answers

this and $(this) in widget

What do this and $(this) mean inside a widget method like create? For example, Having a widget like this, $.widget("sample.CustomWidget", { options:{ }, _create: function(){ // Here what do this and $(this) mean } }); Thanks in advance, -Raja.
Rajagopal 웃
  • 8,061
  • 7
  • 31
  • 43
3
votes
1 answer

jQuery UI widget factory: how to reference widget instance using 'this' inside a options?

I have the following code snippet: $.widget("tj.commonCoordinator", { options: { "obx_type": "common_obx", "obx_callbacks": { request_modify: function(event, ui) { this._loadentries(); }, …
Jinghui Niu
  • 990
  • 11
  • 28
3
votes
2 answers

How to use regular expression in sahi script?

I am using sahi for automate the website, when I record the actions from the sahi recorder then it record click action of a button(actually "span") as _click(_span("Done[4]")); but when I play the recorded script then it got failed on that line as…
BhushanK
  • 1,205
  • 6
  • 23
  • 39
3
votes
2 answers

How do I destroy all jQuery UI widgets?

I have developed a large "single page application" using jQuery and jQuery UI. As I load various sections in the app it creates jQuery UI widgets like dialogs or date pickers. They tend to hang around and cause some issues when I reload certain…
Jeremy
  • 1,023
  • 3
  • 18
  • 33
2
votes
1 answer

Type Error: c is not a constructor/c.widget is not a function

I am trying to get jQuery UI dialogs working on my drupal site. After checking the web console, I found that I was getting the error: $(...).dialog is not a function I did some researching (aka. googling) and I found that this could have been…
anduril
  • 199
  • 2
  • 10
2
votes
2 answers

Why does boolean true have toJSON method in IE?

This is a weird IE quirk. Here are the steps: Go to msn.com in Internet Explorer 8 Pull up dev tools Switch Browser Mode to "IE8 Compat View" Switch Document Mode to "IE7 Standards" Switch to Script tab run the following script: true.toJSON() it…
2
votes
1 answer

Get reference to all instances of jquery ui widget?

I am writing a jquery UI widget that simply wraps the bootstrap popover plugin, In the widget you can pass in the option 'singular', if this is passed in then it should call a function of all other instances of the plugin. something…
Hailwood
  • 89,623
  • 107
  • 270
  • 423
1
vote
1 answer

How can I attach two different callbacks to one jQuery UI widget?

With custom jQuery Ui widget, you can attach your own callback functions to it by passing options to the plugin. However, if I want to attach one callback to "generate_img" event and later on another different but not mutually exclusive behaviour to…
Jinghui Niu
  • 990
  • 11
  • 28
1
vote
0 answers

Basicprimitives org chart node preview working wrong

I successfully create a organizational chart with BasicPrimitives-orgChart but I have a problem with the node's preview when you do mouse hover. Sometimes randomly gray "preview" node appears on the left of the screen. Sometimes the preview shows…
Robert K
  • 130
  • 3
  • 16
1
vote
1 answer

Jquery widget triggered event not being handled or fired

I have a very simple widget outlined that appears to fire an event via _trigger that I cant seem to bind to: ; (function ($) { $.widget('testspace.ftpWidget', { options: {}, widgetEventPrefix: 'ftpwidget:', _create:…
1
vote
1 answer

How in the world to 'trigger' events get bound in custom jQuery-Ui widgets?

I'm trying to integrate this plugin into my app: https://github.com/mar10/jquery-ui-contextmenu/blob/master/jquery.ui-contextmenu.js I'm completely baffled as to how right-clicking an element that matches the delegate selector on an initialized…
RavenHursT
  • 2,336
  • 1
  • 25
  • 46
1
vote
1 answer

How to set the options in jQuery widget Factory with values from server side variables(JSON file)

I want to set the options for widget with JSON file variable values? How can I do it plus how do I pass the json file to the client side? The code is being copied from the jQueryUI Widget Factory