Skip to content
This repository has been archived by the owner on Aug 26, 2020. It is now read-only.

Commit

Permalink
v0.9.7.1
Browse files Browse the repository at this point in the history
          Fixed playing a sound at double volume (actually
          playing it twice overlapping) when you have two chars
          in local seeing the same alert.

          Fixed misparsing of questions that included 'clear' in
          them, such as "Is KBP clr?".  BTW, KBP is never clear.

          Fixed "*DEBUGGING*" entries accidentally inserted in
          channel list.
  • Loading branch information
3vi1 committed Mar 17, 2018
1 parent 5a74909 commit 20436c7
Show file tree
Hide file tree
Showing 12 changed files with 460 additions and 236 deletions.
1 change: 1 addition & 0 deletions data/dictionaries/common
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ in
is
no
on
pi
ship
ships
shiptype
Expand Down
25 changes: 25 additions & 0 deletions docs/JUMPBRIDGES
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
Jumpbridge data should be stored in a plain text file, named the same as the
map (except all lowercase). The file should be placed in the directory
pointed to in settings|options|map(tab)|"Bridge Data".

For instance, if your bridge data directory is set to
"http://eternaldusk.com/imp/jb/", a map for Providence would be located in
the file at "http://eternaldusk.com/imp/jb/providence".

The contents of the file should follow this format:

FirstSystem=SecondSystem:#RGBcolorInHex


Example:

3D-CQU=9UY4-H:#0F00FF
3KB-J0=AY-YCU:#804030
49GC-R=8B-VLX:#1F00EF
5KG-PY=QBL-BV:#2F00DF
7YWV-S=N8XA-L:#3F00CF
...

You can "comment-out" bridges that are temporarily down by replacing the
'=' with another character, like '?'. For instance "3D-CQU?9UY4-H:#0F00FF"
would not be shown on the map and would be ignored.
10 changes: 10 additions & 0 deletions docs/RELEASES
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
0.9.7.1 - Fixed playing a sound at double volume (actually
playing it twice overlapping) when you have two chars
in local seeing the same alert.

Fixed misparsing of questions that included 'clear' in
them, such as "Is KBP clr?". BTW, KBP is never clear.

Fixed "*DEBUGGING*" entries accidentally inserted in
channel list.

0.9.7 - Changed log watching logic to further work around the
post-Vista behavior where NTFS does not update file
modification times until the handle is closed. Hopefully
Expand Down
95 changes: 95 additions & 0 deletions src/eventthread.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
#include "eventthread.h"

EventThread::EventThread(QObject *parent) : QThread(parent)
{
messagesReady = false;
abort = false;
}

EventThread::~EventThread()
{
mutex.lock();
abort = true;
condition.wakeOne();
mutex.unlock();

wait();
}

void EventThread::run()
{
forever {
mutex.lock();
QList<MessageInfo> messages = this->messages;
this->messages.clear();
mutex.unlock();

foreach (MessageInfo message, messages)
{

}

mutex.lock();
if (!messagesReady)
condition.wait(&mutex);
messagesReady = false;
mutex.unlock();
}
}


void EventThread::handleEvents(QList<MessageInfo> messages)
{
QMutexLocker locker(&mutex);

this->messages.append(messages);

if (!isRunning()) {
start(LowPriority);
}
else {
messagesReady = true;
condition.wakeOne();
}
}

/*
void EventThread::initParsing()
{
chatModel->removeRows(0,chatModel->rowCount());
if(parser != NULL)
{
parser->deleteLater();
}
parser = new Parser(++parserGeneration, this);
parser->setMap(*regionMap);
connect(parser, &Parser::newMessages, this, &MainWindow::receiveMessages);
if(lc != NULL)
{
lc->deleteLater();
}
lc = new LogCatcher(&options);
lc->setLogDir(options.getLogPath());
#ifdef USE_FALLBACK_POLLER
lc->setPollerRefresh(options.getPollerRefresh());
#endif
connect(lc, &LogCatcher::fileChanged,
this, &MainWindow::fileChanged);
// Initialize with last session if not old...
foreach(QString absoluteFilePath, lc->files())
{
if((options.getIntelChannels().contains(shortName(absoluteFilePath)) &&
options.getInitOldIntel()) ||
parser->getLocalChannels().contains(shortName(absoluteFilePath)))
{
fileChanged(absoluteFilePath);
}
}
}
*/
43 changes: 43 additions & 0 deletions src/eventthread.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
#ifndef EVENTTHREAD_H
#define EVENTTHREAD_H

#include <QDateTime>
#include <QList>
#include <QMap>
#include <QMutex>
#include <QObject>
#include <QThread>
#include <QWaitCondition>

#include "msg.h" // MessageInfo definition

class EventThread : public QThread
{
Q_OBJECT
public:
explicit EventThread(QObject *parent = nullptr);
~EventThread();

void handleEvents(QList<MessageInfo> messages);
void initParsing();

signals:

public slots:

protected:
void run() override;

private:

// Thread Control
bool abort;
bool messagesReady;
QMutex mutex;
QWaitCondition condition;

QList<MessageInfo> messages;
QMap<QString, QDateTime> soundLastPlayed;
};

#endif // EVENTTHREAD_H
12 changes: 8 additions & 4 deletions src/imp.pro
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ QT += xml xmlpatterns svg widgets
TARGET = imp
TEMPLATE = app

VERSION = 0.9.7
VERSION = 0.9.7.2
QMAKE_TARGET_COMPANY = EternalDusk
QMAKE_TARGET_DESCRIPTION = Eve Online Intelligence Management Program
QMAKE_TARGET_COPYRIGHT = (c) Copyright 2016-2017 Jesse Litton
Expand Down Expand Up @@ -69,7 +69,8 @@ SOURCES += \
combodelegate.cpp \
volumedelegate.cpp \
playdelegate.cpp \
debugmessage.cpp
debugmessage.cpp \
eventthread.cpp

HEADERS += \
mainwindow.h \
Expand Down Expand Up @@ -102,7 +103,9 @@ HEADERS += \
combodelegate.h \
volumedelegate.h \
playdelegate.h \
debugmessage.h
debugmessage.h \
eventthread.h \
msg.h

FORMS += \
mainwindow.ui \
Expand Down Expand Up @@ -135,7 +138,8 @@ DISTFILES += \
../docs/THEMES \
../docs/CREDITS \
../docs/DICTIONARIES \
../INSTALL.md
../INSTALL.md \
../docs/JUMPBRIDGES

RESOURCES += \
resources.qrc
Expand Down
Loading

0 comments on commit 20436c7

Please sign in to comment.