GWT- PopupPanel with search?

I am looking for a way to create a popup dialog box when a user double clicks a textinput field that will contain a scroll-able list (from database table) where the user can select a field, hit ok, and have it placed into the textbox when popup closes.

The other major requirement is to have a filter/ or search field in the popup to aid the user in finding the correct option to select from quicker.

What is the best way to implement this?

Modification to gwt's popup panel? maybe a JOptionPane? are there any simple solutions already designed for free commercial use?

Answers


You could implement this with a com.google.gwt.user.client.ui.PopupPanel. You can make a PopupPanel that contains a ListBox with your data from the database, along with a OK button. When a user selects a value and hits OK, you should utilize an EventBus along with a custom Event that will pass the value to the field on the page. The page will have an event handler that will catch the event and put it into the field.

Another option is to use a com.google.gwt.user.client.ui.SuggestBox. It is a box that autocompletes / suggests values as you type, kind of like the Youtube search bar.

I can offer more resources to help you accomplish this, if you'd like.


Need Your Help

Java EE: Creating and deleting socket listeners dynamically from the domain model

java java-ee domain-driven-design ejb jca

I am creating a Java EE application that allows users to add/remove "socketinfo" tables (stored in a database) from a web interface. If the user enables a "socketinfo" from the web interface, the

Newly added record in datastore is not refelcting in the application

python google-app-engine gae-datastore

I have been facing this problem in app engine. As I am new to App Engine, I don't know whether I am doing it right way or not.

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.