• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

tabFolder, table and SWT.EraseItem problem

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am using SWT to create a GUI for my program.
I have a shell with a tabFolder with two tabItems.
Each of the tabItems controls a different table, so I have two tables in total.
Every 5 minutes I update the contents of both of the tables.
I searched for a way to customize the color of a selected item in a table, and I found information regarding SWT.EraseItem to make this possible.
I used this snippet:


Here is my problem:
When I have selected table2 (tabItem2), and my tables are updated, the first table, table1 gets focus, you can only see table1, though the selected tabItem appears to be tabItem2.
I hope my problem is clear to you, so when updating the tables, the eraseItem listener causes the first table to appear even if the second table is selected.
 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have you found a solution to this issue?
I have just come across the exact same problem and I am not sure how to fix.

 
Bill Coider
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
if you have not found one yet, a workable solution i found is to create the tables inside 'dummy' composites, and then add the composites to the tab folder.
it seems to work ok that way.
does that work for you?
 
Bartender
Posts: 11497
19
Android Google Web Toolkit Mac Eclipse IDE Ubuntu Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Bill,
Welcome to the Ranch.
 
reply
    Bookmark Topic Watch Topic
  • New Topic