Last modified: 2012-02-24 02:52:09 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T33460, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 31460 - Hardware search button not wired to actually search
Hardware search button not wired to actually search
Status: RESOLVED FIXED
Product: Wikipedia App
Classification: Unclassified
Generic (Other open bugs)
1.0.0 (Android)
All All
: High major
: ---
Assigned To: Anis Kadri
:
Depends on:
Blocks: 31447
  Show dependency treegraph
 
Reported: 2011-10-07 00:34 UTC by Tomasz Finc
Modified: 2012-02-24 02:52 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: Android
Assignee Huggle Beta Tester: ---


Attachments

Description Tomasz Finc 2011-10-07 00:34:26 UTC
We should be able to use the search button on the phone to do searches.
Comment 1 Tomasz Finc 2011-10-07 00:35:16 UTC
First filed at : https://github.com/nitobi/Wikipedia/issues/18
Comment 2 Brion Vibber 2011-10-08 04:36:10 UTC
The event handler gets fired, and it seems to be legit calling focus() on the right element. There's already a comment in indicating that it's not working for some unknown reason...

I tried calling it from a setTimeout callback, or blur()ing before focus(), no dice.

A little experimenting (loading a link to a page with an input box on it, tapping into *that* input box to make sure something else was focused, and then hitting the 'search' button) seems to indicate that it *is* setting focus to the search field! However... it doesn't activate the soft keyboard. And if we were previously in another field with the keyboard open, the soft keyboard *closes*.

wtf!
Comment 3 Brion Vibber 2011-10-08 06:16:41 UTC
This PhoneGap plugin with an API to hide or show the soft keyboard might help:
https://github.com/phonegap/phonegap-plugins/tree/master/Android/SoftKeyboard
Comment 4 herman wong 2011-10-11 21:49:19 UTC
added the soft keyboard plugin: https://github.com/nitobi/Wikipedia/commit/7e6102775d85864cae51b61b7aa4e7875ac927b1

when pressing the search button the keyboard will display, when the user types in the keyboard the characters & cursor then appear in the input field.

the cursor doesn't appear in the input field if the hardware search button is pressed and the user doesn't enter any characters with the keyboard.

still need to determine why the cursor isn't appearing when the focus() method is called.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links