Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Highlighted
New Developer
Posts: 8
Registered: ‎06-05-2009
My Device: Not Specified
Accepted Solution

Using PasswordEditField to enable multi tap

I've had a problem disabling SureType like so many others here. The solutions I found here worked only partially. So we came up with a solution that disables SureType on all devices regardless of users locale. We subclassed password edit field and made it display actual text instead of asterisks.

protected void paint(Graphics graphics) { graphics.drawText(getText(), 0, 0); }

 The only method we redefined is paint as shown on the listing.There is one problem with this solution. The cursor position matches the text as it is all made of asterisks which is not the case. After couple of characters entered to cursor moves away far away from the text. I haven't been able to change the way cursor is positioned. None of the methods I saw in the API seemed to do the trick. Also, decompiling the PasswordEditField.class produced no results as it was implemented in native language. Does anyone know how to deal with cursor positioning? I would appreciate any kind of help. Thx.

 

 

Developer
Posts: 304
Registered: ‎08-01-2008
My Device: Not Specified

Re: Using PasswordEditField to enable multi tap

You want multi-tap try this:

 

 

EditField ef = new EditField(TextField.NO_COMPLEX_INPUT);

 

 

 

New Developer
Posts: 8
Registered: ‎06-05-2009
My Device: Not Specified

Re: Using PasswordEditField to enable multi tap

Thanks a lot! This solved the problem.
New Member
Posts: 1
Registered: ‎04-17-2010
My Device: Storm 2
My Carrier: Verizon

Re: Using PasswordEditField to enable multi tap

How do you do this??