🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #1019

CardLayout

#1019
From: Alex Stylianos
Date: Tue, 14 Sep 2004 06:02
24 lines
1693 bytes
Hi all

I suppose this must be a common problem but I cannot find a good solution:

I am using JDK 1.4.2_01-b06 and the problem is that I cannot have a 
CardLayout switch cards properly.
There are no errors reported by JBuilder but the CardLayout does not update 
as it should. I have tried switching panels with the following 3 different 
ways:

1) ((CardLayout)pnMain.getLayout()).show(pnMain, pn);  // where pn is the 
name of the new panel

2) explicitly hidding all cards and showing the one that should be in front

3) starting a JTimer with an interval of 3 seconds (3000 msec) in order to 
avoid the collision of multiple repaint() calls

nothing seems to work as it should

is this a known problem? or what am I missing??

TIA
Alex 
Technical Details
Message-ID: <41468990@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 111d45,5ea5dd499f3c6a16,start
X-Google-Attributes: gid111d45,public
X-Google-Language: ENGLISH,ASCII-7-bit
Reply-To: "Alex Stylianos" <alex@dreamedge.com>
From: "Alex Stylianos" <alex@dreamedge.com>
Newsgroups: borland.public.jbuilder.java.swing
Subject: CardLayout
Date: Tue, 14 Sep 2004 09:02:59 +0300
Lines: 26
Organization: none
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 212.54.223.217
Message-ID: <41468990@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1095141776 212.54.223.217 (13 Sep 2004 23:02:56 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail