1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2025-02-19 09:54:15 +01:00

OP-244 Attempt to solve the issue. Cannot reproduce on my system, but I have made a few changes to declare the OP_DFU::Status using the Q_ENUMS macro.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2347 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
edouard 2011-01-08 13:22:15 +00:00 committed by edouard
parent d8022a320d
commit d6cb01edf2
3 changed files with 6 additions and 3 deletions

View File

@ -5,9 +5,9 @@
* @author The OpenPilot Team, http://www.openpilot.org Copyright (C) 2010.
* @addtogroup GCSPlugins GCS Plugins
* @{
* @addtogroup YModemUploader YModem Serial Uploader Plugin
* @addtogroup Uploader Serial and USB Uploader Plugin
* @{
* @brief The YModem protocol serial uploader plugin
* @brief The USB and Serial protocol uploader plugin
*****************************************************************************/
/*
* This program is free software; you can redistribute it and/or modify
@ -266,7 +266,7 @@ void deviceWidget::uploadFinished(OP_DFU::Status retstatus)
{
disconnect(m_dfu, SIGNAL(uploadFinished(OP_DFU::Status)), this, SLOT(uploadFinished(OP_DFU::Status)));
disconnect(m_dfu, SIGNAL(progressUpdated(int)), this, SLOT(setProgress(int)));
disconnect(m_dfu, SIGNAL(operationProgress(QString)), this, SLOT(status(QString)));
disconnect(m_dfu, SIGNAL(operationProgress(QString)), this, SLOT(dfuStatus(QString)));
if(retstatus != OP_DFU::Last_operation_Success) {
status(QString("Upload failed with code: ") + m_dfu->StatusToString(retstatus).toLatin1().data(), STATUSICON_FAIL);
return;

View File

@ -37,6 +37,7 @@ DFUObject::DFUObject(bool _debug,bool _use_serial,QString portname): debug(_debu
info = NULL;
qRegisterMetaType<OP_DFU::Status>("Status");
if(use_serial)
{
PortSettings settings;

View File

@ -39,6 +39,7 @@ namespace OP_DFU {
bytetobytecompare
};
Q_ENUMS(Status)
enum Status
{
DFUidle,//0
@ -87,6 +88,7 @@ namespace OP_DFU {
Status_Rep,//12
};
struct device
{
int ID;