Make sure that BaseWorker deletes the thread when is finished.

Implemented ClientManager so it can manage the usb and wireless threads.
Impelmented better mutex logic on CmaClient.
Execute the cma events in a different thread so the event listener is
available.
Code refactoring.
Fix memory leaks in threads.
Updated readme.
This commit is contained in:
codestation
2013-08-25 01:40:14 -04:30
parent dfdd79e850
commit 92f4572814
29 changed files with 523 additions and 411 deletions

View File

@@ -21,18 +21,14 @@
#define MAINWIDGET_H
#include "configwidget.h"
#include "clientmanager.h"
#include "cmaclient.h"
#include <QAction>
#include <QWidget>
#include <QSystemTrayIcon>
extern "C" {
#include <vitamtp.h>
}
class QMenu;
class MainWidget : public QWidget
{
@@ -44,9 +40,9 @@ public:
void prepareApplication();
private:
void connectSignals();
void createTrayIcon();
void checkSettings();
void connectClientSignals(CmaClient *client);
bool first_run;
ConfigWidget dialog;
@@ -54,7 +50,7 @@ private:
QAction *quit;
QAction *reload;
QAction *options;
CmaClient clientLoop;
ClientManager manager;
const static QStringList path_list;
private slots:
@@ -63,8 +59,6 @@ private slots:
void receiveMessage(QString message);
void setTrayTooltip(QString message);
void showPin(int pin);
void refreshDatabase();
void startServer();
void stopServer();
};