Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2012
    Rep Power

    Post LWUIT Tabs Click Event

    I've created LWUIT tabs ,when the user clicks on any tab ,i want to read an Rss File and i want to display titles with images. Here i am able to load lists related to specific tab individually whenever user clicks on any tab,But the problem comes when the user initially clicks on first tab ,then the titles related to that tab are gets loading,In the middle if the end user clicks on second tab then the titles from tab 1 are getting mix with titles from tab2 and are displayed on tab2..

    Here my code:

    In the Constructor:
    cinemanews = new Vector();
    gossipnews=new Vector();
    cinemaNewsList = new List(cinemanews);
    cinemaNewsList.setRenderer(new NewsListCellRenderer());
    gossipNewsList = new List(gossipnews);
    gossipNewsList.setRenderer(new NewsListCellRenderer());
    Button b1=new Button("CinemaNews");
    Button b2=new Button("GossipNews");
    tabs.addTab(b1, cinemaNewsList);
    tabs.addTab(b2,gossipNewsList );
    b2.addActionListener(new ActionListener() {

    public void actionPerformed(ActionEvent ae) {
    if (cinemanewsList .size() == 0) {
    Condition = tabs.getTabTitle(1);
    b3.addActionListener(new ActionListener() {

    public void actionPerformed(ActionEvent ae) {
    if (gossipNewsList.size() == 0) {

    Condition = tabs.getTabTitle(2);

    form1.addComponent(BorderLayout.CENTER, tabs);
    Here my Condition:

    if (Condition.equals("CinemaNews")) {
    if (Condition.equals("GossipNews")) {
    Can any one pls.. help me ?Is this correct way to identify LWUIT Tab Click Event?

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Madgaon, Goa, India
    Rep Power

    Default Re: LWUIT Tabs Click Event

    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. Click out event
    By rulych in forum AWT / Swing
    Replies: 3
    Last Post: 02-17-2011, 04:43 PM
  2. Double click event
    By Dipke in forum New To Java
    Replies: 3
    Last Post: 10-22-2010, 11:39 AM
  3. click event
    By raman_v in forum Java Servlet
    Replies: 2
    Last Post: 01-08-2010, 12:05 PM
  4. AWT - catching click button event
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 03-11-2008, 11:02 PM
  5. How to perform some event to button click
    By eva in forum AWT / Swing
    Replies: 2
    Last Post: 01-16-2008, 12:27 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts