mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-06 10:15:38 +08:00
refs #288, some GUI elements
* tick label, shows OK/failure * serverlist selector, select 1 of servers * used tick label in selcal selector * fixed include in transponder mode selector
This commit is contained in:
committed by
Roland Winklmeier
parent
0098fd3d58
commit
89806e69ce
49
src/blackgui/serverlistselector.h
Normal file
49
src/blackgui/serverlistselector.h
Normal file
@@ -0,0 +1,49 @@
|
||||
/* Copyright (C) 2013
|
||||
* swift project Community / Contributors
|
||||
*
|
||||
* This file is part of swift project. It is subject to the license terms in the LICENSE file found in the top-level
|
||||
* directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project,
|
||||
* including this file, may be copied, modified, propagated, or distributed except according to the terms
|
||||
* contained in the LICENSE file.
|
||||
*/
|
||||
|
||||
//! \file
|
||||
|
||||
#ifndef BLACKGUI_SERVERLISTSELECTOR_H
|
||||
#define BLACKGUI_SERVERLISTSELECTOR_H
|
||||
|
||||
#include <QComboBox>
|
||||
#include <QStringList>
|
||||
|
||||
#include "blackmisc/nwserverlist.h"
|
||||
|
||||
namespace BlackGui
|
||||
{
|
||||
//! List of servers
|
||||
class CServerListSelector : public QComboBox
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
//! Constructor
|
||||
explicit CServerListSelector(QWidget *parent = nullptr);
|
||||
|
||||
//! Set the servers
|
||||
void setServers(const BlackMisc::Network::CServerList &servers);
|
||||
|
||||
//! Get the current server
|
||||
BlackMisc::Network::CServer currentServer() const;
|
||||
|
||||
private:
|
||||
|
||||
//! Build the item string descriptions
|
||||
void setItemStrings(const BlackMisc::Network::CServerList &servers);
|
||||
|
||||
BlackMisc::Network::CServerList m_servers; //!< corresponding servers
|
||||
QStringList m_items; //!< items strings
|
||||
|
||||
};
|
||||
|
||||
} // namespace
|
||||
|
||||
#endif // guard
|
||||
Reference in New Issue
Block a user