Skip to content
This repository was archived by the owner on Oct 8, 2021. It is now read-only.

"Filterable inside custom select" demo fails on pressing ENTER in search field. #7405

Closed
slavap opened this issue May 14, 2014 · 2 comments · Fixed by #7411
Closed

"Filterable inside custom select" demo fails on pressing ENTER in search field. #7405

slavap opened this issue May 14, 2014 · 2 comments · Fixed by #7411

Comments

@slavap
Copy link

slavap commented May 14, 2014

See http://demos.jquerymobile.com/1.4.2/selectmenu-custom-filter/

form.submit( function () { return false; } ); // fix for ENTER key press

must be added after form creation.

Also there should be else branch added to if clause:
if ( !form ) { ... }
else { input = form.find( "input" ); }

@slavap
Copy link
Author

slavap commented May 14, 2014

Also check commas in your var declarations.

var input,
    list = $( event.target )
    form = list.jqmData( "filter-form" );

IMO must be:

var input,
    list = $( event.target ),
    form = list.jqmData( "filter-form" );

Look at "listviewcreate" and "pagebeforeshow"

@gabrielschulhof
Copy link

@slavap thanks for the heads-up. The submit issue is already fixed in the latest version.

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

Successfully merging a pull request may close this issue.

3 participants