🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: JComboBox question

#11194
From: Rich Wilkman
Date: Thu, 24 Jun 1999 00:00
75 lines
2661 bytes
Arn:

Because you have mixed lightweight and heavyweight components.  The
window for the drop down cannot come up in front of the heavyweight
container.  Check your hintsandtips.txt file for a starting point on
heavyweight v. lightweight.  There's a reference to an excellent article
on the Javasoft site there, too.

-Rich

Arn Cota wrote:
> 
> How come when I add a combo box to my Frame, it does not drop down when I
> click on it?  I can cursor up and down through the items, so I know they are
> on the list, but no drop down:
> 
> Thanks,
> Arn
> ****************
> package Combo;
> 
> import java.awt.*;
> import java.awt.event.*;
> import com.borland.jbcl.control.*;
> import com.borland.jbcl.layout.*;
> import javax.swing.*;
> 
> public class Frame1 extends DecoratedFrame
> {
>   XYLayout xYLayout2 = new XYLayout();
>   BevelPanel bevelPanel1 = new BevelPanel();
>   BorderLayout borderLayout1 = new BorderLayout();
>   JComboBox jComboBox1;
> 
>   //Construct the frame
>   public Frame1()
>   {
>     try
>     {
>       jbInit();
>     }
>     catch(Exception e)
>     {
>       e.printStackTrace();
>     }
>   }
> 
>   //Component initialization
>   private void jbInit() throws Exception
>   {
>     String str[] = {"test1","test2"};
>     this.setLayout(borderLayout1);
>     this.setSize(new Dimension(400, 300));
>     this.setTitle("Frame Title");
>     bevelPanel1.setLayout(xYLayout2);
>     this.add(bevelPanel1, BorderLayout.CENTER);
>     jComboBox1 = new JComboBox(str);
>     bevelPanel1.add(jComboBox1, new XYConstraints(50, 85, 277, 21));
>   }
> }

-- 

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Rich Wilkman
Senior Quality Assurance Engineer
Borland JBuilder Team

If you see something that looks like an opinion up there,
it's mine and mine alone.

Mail sent to me from the newsgroups won't bounce but will
be ignored.  If I have time, I'll respond, but you  have
a better chance if you confine your posts to the newsgroups
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Technical Details
Message-ID: <37729894.2B81A199@inprise.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <7ktsj2$dcg4@forums.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,4cc2568a011ad4de
X-Google-Attributes: gid111d45,public
From: Rich Wilkman <rwilkman@inprise.com>
Subject: Re: JComboBox question
Date: 1999/06/24
Message-ID: <37729894.2B81A199@inprise.com>
X-Deja-AN: 493512828
Content-Transfer-Encoding: 7bit
References: <7ktsj2$dcg4@forums.borland.com>
X-Accept-Language: en
Content-Type: text/plain; charset=us-ascii
Organization: Another Netscape Collabra Server User
Mime-Version: 1.0
Newsgroups: borland.public.jbuilder.java.swing