From a30f374bd5eb28d573845c798ed1b8b93ecdd903 Mon Sep 17 00:00:00 2001 From: David Capello Date: Wed, 6 May 2015 13:07:54 -0300 Subject: [PATCH] Don't popup an empty listbox if the combobox is editable and has open-on-click style --- src/ui/combobox.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ui/combobox.cpp b/src/ui/combobox.cpp index 2244d2983..a2ee62e86 100644 --- a/src/ui/combobox.cpp +++ b/src/ui/combobox.cpp @@ -436,7 +436,9 @@ bool ComboBoxEntry::onProcessMessage(Message* msg) break; case kMouseDownMessage: - if (m_comboBox->isClickOpen()) { + if (m_comboBox->isClickOpen() && + (!m_comboBox->isEditable() || + !m_comboBox->m_items.empty())) { m_comboBox->switchListBox(); }