Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work with jQuery UI 1.9.0+ #11

Open
MikeKingery opened this issue Mar 6, 2013 · 6 comments
Open

Doesn't work with jQuery UI 1.9.0+ #11

MikeKingery opened this issue Mar 6, 2013 · 6 comments

Comments

@MikeKingery
Copy link

When I updated jQuery UI to version 1.9.0 or higher I start getting the following error:

cannot call methods on AddToCal prior to initialization; attempted to call method 'close'

This stems from the following call within toggleMenu:

$('.ui-addtocal').AddToCal( 'close' );

@tardate
Copy link
Owner

tardate commented Mar 7, 2013

Hi Mike,

Thanks for looking into this. I need all the help I can get to keep this maintained;-)

To be honest, I am moving away from jQuery UI wherever possible and not using on new projects. So I'm wondering if rather than make it jQuery UI 1.9 compatible, would it be best to refactor this completely to remove the jQueryUI dependency?

@MikeKingery
Copy link
Author

I haven't done much plugin development with jQuery UI so I'll go with whatever is your suggestion.

@xgretsch
Copy link

xgretsch commented Mar 5, 2014

Removing dependency on jQuery UI is a good idea, because the download is very large (can be 200 kbytes plus). Currently trying to use this and falling foul of this problem - is there a known workaround?

@ksburrell
Copy link

I made this work wtih 1.9 by making the following changes in jquery.addtocal.js:

  1. Changed "selected" event to "select" when intializing the menu widget in _create().
  2. Changed "deactivate" calls to "collapse" on the menu property
  3. Changed $('.ui-addtocal').AddToCal('close') to $('.ui-addtocal').find('input').AddToCal('close');

@tardate
Copy link
Owner

tardate commented Dec 29, 2014

@cincobyte good stuff. If you can send a pull request with your changes, I'm happy to roll them in.

@ghost
Copy link

ghost commented Aug 18, 2017

Hi,
We have updated the jquery to 1.9.1 and jqueryui to 1.11.3 and getting below issues:
Error : this.menu.'element' is undefined at t.(anonymous function).(anonymous function).toggleMenu
Please help and suggest a workaround.
Thanks,
Chandra

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants