Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!goblin1!goblin2!goblin.stu.neva.ru!newsfeed1.swip.net!uio.no!ntnu.no!not-for-mail From: Bent C Dalager Newsgroups: comp.lang.java.gui Subject: Re: JComboBox drop-down arrow disappears Date: Wed, 2 Nov 2011 09:41:46 +0000 (UTC) Organization: Norwegian university of science and technology Lines: 18 Message-ID: References: NNTP-Posting-Host: microbel.pvv.ntnu.no X-Trace: orkan.itea.ntnu.no 1320226906 1392 129.241.210.179 (2 Nov 2011 09:41:46 GMT) X-Complaints-To: usenet@ntnu.no NNTP-Posting-Date: Wed, 2 Nov 2011 09:41:46 +0000 (UTC) User-Agent: slrn/pre1.0.0-18 (Linux) Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.gui:4735 On 2011-11-01, Amandil wrote: > Does anyone else have this problem? Is it documented anywhere? Calling > removeAllItems() on a JComboBox caused the drop-down arrow to > disappear. It did not reappear even after the JComboBox was > repopulated. From memory, this happens if you call removeAll() on the combo, which causes the Container superclass to remove all the components that were used to give the combobox its appearance. (Results may vary from one PLAF to the next on this, don't know but it seems likely enough.) You probably mistakenly called removeAll() when you were intending to call removeAllItems(). They do very different things. Bent. -- Bent Dalager - bcd@pvv.org - http://www.pvv.org/~bcd powered by emacs