Skip to content

Commit

Permalink
Merge branch 'develop-gov' into release
Browse files Browse the repository at this point in the history
  • Loading branch information
maisvendoo committed Mar 14, 2020
2 parents 54391af + 2a0a889 commit 2924087
Show file tree
Hide file tree
Showing 249 changed files with 6,853 additions and 3,496 deletions.
604 changes: 302 additions & 302 deletions LICENSE-Russian

Large diffs are not rendered by default.

18 changes: 9 additions & 9 deletions RRS.pro
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,29 @@ SUBDIRS += ./CfgReader
SUBDIRS += ./CfgEditor
SUBDIRS += ./filesystem
SUBDIRS += ./libJournal
SUBDIRS += ./log
SUBDIRS += ./tcp-connection
SUBDIRS += ./asound
SUBDIRS += ./simulator

SUBDIRS += ./addons/default-vehicle
SUBDIRS += ./addons/test-loco
SUBDIRS += ./addons/sapsan-motor
SUBDIRS += ./addons/sapsan-non-motor
SUBDIRS += ./addons/es1-motor
SUBDIRS += ./addons/es1-non-motor
SUBDIRS += ./viewer

SUBDIRS += ./addons/passcar
SUBDIRS += ./addons/vl60
SUBDIRS += ./addons/tep70
#SUBDIRS += ./addons/chs4t
SUBDIRS += ./addons/chs2t
SUBDIRS += ./addons/ep20

SUBDIRS += ./launcher
SUBDIRS += ./launcher2

SUBDIRS += ./viewer

SUBDIRS += ./tools/profconv
SUBDIRS += ./tools/pathconv
SUBDIRS += ./tools/routeconv

#SOURCES += \
# addons/vl60/vl60-equipment/src/tapping-sound.cpp \
# addons/vl60/vl60-equipment/src/tapping-sound.cpp

#HEADERS += \
# addons/vl60/vl60-equipment/include/tapping-sound.h
6 changes: 3 additions & 3 deletions addons/chs2t/chs2t/include/chs2t-horn.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ class CHS2tHorn : public TrainHorn

void stepKeysControl(double t, double dt)
{
//TrainHorn::stepKeysControl(t, dt);
TrainHorn::stepKeysControl(t, dt);

if (control_signals.analogSignal[KM_SVISTOK].is_active)
/*if (control_signals.analogSignal[KM_SVISTOK].is_active)
{
if (is_svistok = static_cast<bool>(control_signals.analogSignal[KM_SVISTOK].cur_value))
{
Expand All @@ -28,7 +28,7 @@ class CHS2tHorn : public TrainHorn
{
emit soundSetVolume("Svistok", 0);
}
}
}*/
}
};

Expand Down
5 changes: 0 additions & 5 deletions addons/default-vehicle/default-vehicle.pro

This file was deleted.

32 changes: 0 additions & 32 deletions addons/default-vehicle/default-vehicle/default-vehicle.pro

This file was deleted.

14 changes: 0 additions & 14 deletions addons/default-vehicle/default-vehicle/include/default-vehicle.h

This file was deleted.

13 changes: 0 additions & 13 deletions addons/default-vehicle/default-vehicle/src/default-vehicle.cpp

This file was deleted.

32 changes: 32 additions & 0 deletions addons/ep20/blok-display/blok-display.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
TEMPLATE = lib

QT += core
QT += gui
QT += widgets
QT += opengl
QT += xml

TARGET = blok-display

DESTDIR = ../../../../modules/ep20

CONFIG(debug, debug|release) {

LIBS += -L../../../../lib -ldisplay_d
LIBS += -L../../../../lib -lCfgReader_d

} else {

LIBS += -L../../../../lib -ldisplay
LIBS += -L../../../../lib -lCfgReader
}

INCLUDEPATH += ./include
INCLUDEPATH += ../ep20/include
INCLUDEPATH += ../../../simulator/vehicle/include
INCLUDEPATH += ../../../CfgReader/include
INCLUDEPATH += ../../../viewer/display/include

HEADERS += $$files(./include/*.h)
SOURCES += $$files(./src/*.cpp)
RESOURCES += $$files(./resources/*.qrc)
42 changes: 42 additions & 0 deletions addons/ep20/blok-display/include/DisconnectionServer.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
//-----------------------------------------------------------------------------
//
// Экран потери связи
// (c) РГУПС, ВЖД 18/07/2017
// Разработал: Даглдиян Б.Д.
//
//-----------------------------------------------------------------------------
/*!
* \file
* \brief Экран потери связи
* \copyright РГУПС, ВЖД
* \author Даглдиян Б.Д.
* \date 18/07/2017
*/

#ifndef DISCONNECTIONSERVER_H
#define DISCONNECTIONSERVER_H

#include <QLabel>
#include <QPainter>

/*!
* \class DisconnectionServer
* \brief Класс, вызываемый при потере связи с сервером
*/
class DisconnectionServer : public QLabel
{

public:
/*!
* \brief Конструктор.
* \param size - размер элемента
*/
DisconnectionServer(QSize size, QWidget* parent = Q_NULLPTR);

/// Деструктор
~DisconnectionServer();


};

#endif // DISCONNECTIONSERVER_H
50 changes: 50 additions & 0 deletions addons/ep20/blok-display/include/ImageLabel.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
#ifndef IMAGE_LABEL_H
#define IMAGE_LABEL_H

#include <QLabel>
#include <QPainter>

class ImageLabel : public QLabel
{
public:

ImageLabel(QWidget *parent = Q_NULLPTR) : QLabel(parent)
, pixmap(Q_NULLPTR)
{

}

ImageLabel(const QString &text, QWidget *parent = Q_NULLPTR) : QLabel(text, parent)
, pixmap(Q_NULLPTR)
{

}

virtual ~ImageLabel()
{

}

void setPixmap(QPixmap *pxmp)
{
pixmap = pxmp;
}


private:

QPixmap *pixmap;

void paintEvent(QPaintEvent *)
{
if (pixmap == Q_NULLPTR)
return;

QPainter p(this);
p.setWindow(this->frameGeometry());
p.drawPixmap(this->frameGeometry(), *pixmap);
}
};


#endif // IMAGE_LABEL_H
84 changes: 84 additions & 0 deletions addons/ep20/blok-display/include/InformPart.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
//-----------------------------------------------------------------------------
//
// Элемент блока информации
// (c) РГУПС, ВЖД 12/04/2017
// Разработал: Даглдиян Б.Д.
//
//-----------------------------------------------------------------------------
/*!
* \file
* \brief Класс элемента блока информации
* \copyright РГУПС, ВЖД
* \author Даглдиян Б.Д.
* \date 12/04/2017
*/

#ifndef INFORMPART_H
#define INFORMPART_H


#include <QLabel>
#include <QPainter>
#include <QImage>

#include "ImageLabel.h"

/*!
* \class InformPart
* \brief Класс, описывающий элемент блока информации
*/
class InformPart : public ImageLabel
{
Q_OBJECT

public:
/*!
* \brief Конструктор. Рисуем элемент информационного блока
* \param geo - геометрия элемента (позиция, размер)
* \param strHead - текст заголовка
* \param strText - текст
* \param align - выравнивание
* \param marginLeft - отступ текста слева
* \param isDrawX - рисовать ли крестик
* \param isDrawO - рисовать ли эллипс
*/
InformPart( QRect geo, QString strHead, QString strText,
Qt::Alignment align, QWidget *parent = Q_NULLPTR,
QString config_path = "",
int marginLeft =0, bool isDrawX =false, bool isDrawO =false );
/// Деструктор
~InformPart();

/*!
* \brief Установить текст элемента
* \param strText - текст
*/
void setText(QString strText);

void setTextOverHead(QString headText, QRect geo);

void setImgOverLabel();

private:

QLabel* labelText_; ///< виждет для отображения текста элемента
QLabel* labelTextOverHead_; ///< перекрывающий текст заголовка
int fooWidth_;

void drawX(); ///< Нарисовать крестик
void drawO(); ///< Нарисовать эллипс

// --- cfg параметры --- //
QString colorBorder_;
QString colorTextHead_;
QString colorText_;
int fontSize_;
// --------------------- //

QPixmap pm;

/// Чтение конфигураций
bool loadInformPartCfg(QString cfg_path);
};

#endif // INFORMPART_H
Loading

0 comments on commit 2924087

Please sign in to comment.