Article View: borland.public.jbuilder.java.swing
Article #9547Leaving a JTabbedPane
From: Jeff Marendo
Date: Mon, 13 Mar 2000 00:00
Date: Mon, 13 Mar 2000 00:00
20 lines
1548 bytes
1548 bytes
Hello, I have a JTabbedPane with several tabs on it. Each tab has a panel with components that a user will be using to enter and view data. On one of my tabs, a user can initiate a process to create a new "widget". I want to make it so that if a user initiates that process, but decides to switch to another tab before hitting a "confirm" button, a JDialogBox will be displayed to the user (before showing the tab they're trying to click on) informing them that they didn't confirm their change and that if they leave, they'll lose all of their changes. I plan on using a "dirty" flag to track whether or not they tried to initiate the new widget process. However, I don't know how to go about tracking when they try to leave this tab and firing off the JDialogBox BEFORE showing the other tab they're trying to switch to (I don't care if they're just switching between different windows applications). Can anyone give me any pointers or suggestions how to go about this? Thanks in advance. Jeff
Technical Details
Message-ID:
<8ajqhi$p9v6@bornews.borland.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111d45,43d6d60a05065d15,start X-Google-Attributes: gid111d45,public From: "Jeff Marendo" <marendoj@commos.com> Subject: Leaving a JTabbedPane Date: 2000/03/13 Message-ID: <8ajqhi$p9v6@bornews.borland.com> X-Deja-AN: 597067218 X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2615.200 Organization: CommTech Corporation X-MSMail-Priority: Normal Reply-To: "Jeff Marendo" <marendoj@commos.com> Newsgroups: borland.public.jbuilder.java.swing