Win a copy of Soft Skills: The software developer's life manual this week in the Jobs Discussion forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Producing Virtual Keypad on Custom Items

 
Nikhil Shravane
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Everyone,

I have developed a midlet with some custom items. When midlet starts it shows the login screen with the custom designed USERNAME and PASSWORD fields. When user enters letters/numbers through the keypad on the device, they get displayed in the selected custom item. I have managed to give the same effect as like of actual standard TextField.

But it requires keypad on the device. It wont work on the full touch screen phones, as there is no way to enter letters/numbers on the full touch screen devices.

On full touch screen, if I touch on the standard TextField [not custom designed], application produces virtual keypad on the screen. In the same way, What should I do so that application can produce the virtual keypad when user touches the custom item?

Best Regards
 
Carol Hamer
author
Greenhorn
Posts: 26
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just to clarify: You're writing this as a MIDlet, and not as a CLDC application? So your custom text field extends javax.microedition.lcdui.CustomItem instead of being a net.rim.device.api.ui.component? Is there a reason you're using the MIDlet API instead of using RIM's user interface classes?

It's probably simpler to use the net.rim.device.api.ui classes. In that case you can implement your custom field's onFocus and onUnfocus methods to show and hide the virtual keyboard (net.rim.device.api.ui.VirtualKeyboard).
 
Nikhil Shravane
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Carol,

Yes you are right, I am not using RIM API as I want my midlet to be cross-platform.

In my midlet I have used STANDARD TEXT FIELD which is available in the Java MIDP API. It produce the virtual keypad when I touch this standard text field which comes with the Java MIDP API.

In the same way what should I do so that it can produce the virtual keypad even on custom items also?

Best Regards
 
Carol Hamer
author
Greenhorn
Posts: 26
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
RIM has some APIs that extend the MIDlet user interface APIs -- I would start there.

Have you tried using net.rim.device.api.lcdui.BlackBerryCustomItem? The JavaDoc says "This class extends the functionality of the javax.microedition.lcdui.CustomItem class to include full touch support."
 
Nikhil Shravane
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, I got that. But then I'll have to use RIM API, so it will not be cross-platform. On touching custom text field, it should produce virtual keypad which is provided by the device vendor. IE on Samsung full touch screen, it will produce Samsung's virtual keypad, and on Nokia full touch, it will produce Nokia's virtual key pad. Are you getting me? Is there nay way or setting to achieve this? Best Regards.
 
Don't get me started about those stupid light bulbs.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic