refs #300, moved models in own namespace and directory

This commit is contained in:
Klaus Basan
2014-07-27 14:53:15 +02:00
parent 4e9828b724
commit c500a561be
40 changed files with 1759 additions and 1606 deletions

View File

@@ -0,0 +1,53 @@
/* Copyright (C) 2013 VATSIM Community / contributors
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/*!
\file
*/
#ifndef BLACKGUI_ATCLISTMODEL_H
#define BLACKGUI_ATCLISTMODEL_H
#include "blackmisc/avatcstationlist.h"
#include "blackgui/models/listmodelbase.h"
#include <QAbstractItemModel>
#include <QDBusConnection>
namespace BlackGui
{
namespace Models
{
//! ATC list model
class CAtcStationListModel : public CListModelBase<BlackMisc::Aviation::CAtcStation, BlackMisc::Aviation::CAtcStationList>
{
public:
//! What kind of stations
enum AtcStationMode
{
NotSet,
StationsBooked,
StationsOnline
};
//! Constructor
explicit CAtcStationListModel(AtcStationMode stationMode, QObject *parent = nullptr);
//! Destructor
virtual ~CAtcStationListModel() {}
//! Set station mode
void setStationMode(AtcStationMode stationMode);
public slots:
//! Used to quickly update single station (better response for the user)
void changedAtcStationConnectionStatus(const BlackMisc::Aviation::CAtcStation &station, bool added);
private:
AtcStationMode m_stationMode;
};
}
}
#endif // guard