mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-01 05:26:45 +08:00
refs #634, fixes and improvements in selectors/completers
* upper case * get raw data from selector * sort completers
This commit is contained in:
@@ -12,6 +12,7 @@
|
||||
#include "blackgui/guiapplication.h"
|
||||
#include "blackgui/uppercasevalidator.h"
|
||||
#include "blackmisc/datastoreutility.h"
|
||||
#include "blackmisc/stringutils.h"
|
||||
#include <QMimeData>
|
||||
|
||||
using namespace BlackGui;
|
||||
@@ -79,6 +80,11 @@ namespace BlackGui
|
||||
this->ui->le_Aircraft->setReadOnly(readOnly);
|
||||
}
|
||||
|
||||
QString CDbAircraftIcaoSelectorComponent::getRawDesignator() const
|
||||
{
|
||||
return stripDesignatorFromCompleterString(ui->le_Aircraft->text());
|
||||
}
|
||||
|
||||
void CDbAircraftIcaoSelectorComponent::withIcaoDescription(bool description)
|
||||
{
|
||||
this->ui->lbl_Description->setVisible(description);
|
||||
@@ -141,7 +147,7 @@ namespace BlackGui
|
||||
{
|
||||
if (count > 0)
|
||||
{
|
||||
QCompleter *c = new QCompleter(sGui->getWebDataServices()->getAircraftIcaoCodes().toCompleterStrings(true, true), this);
|
||||
QCompleter *c = new QCompleter(sGui->getWebDataServices()->getAircraftIcaoCodes().toCompleterStrings(true, true, true), this);
|
||||
c->setCaseSensitivity(Qt::CaseInsensitive);
|
||||
c->setCompletionMode(QCompleter::PopupCompletion);
|
||||
c->setMaxVisibleItems(10);
|
||||
|
||||
Reference in New Issue
Block a user