Updraft
1.0
Open source glider flight visualisation tool.
|
Top leve object of IGC viewer plugin. More...
#include <igcviewer.h>
Public Member Functions | |
QString | getName () |
Plugin metadata. | |
void | initialize (CoreInterface *coreInterface) |
Called after the plugin is loaded. | |
void | deinitialize () |
Called before the plugin is unloaded. | |
bool | fileOpen (const QString &filename, int roleId) |
Callback to open a file. | |
void | fileIdentification (QStringList *roles, QString *importDirectory, const QString &filename) |
bool | wantsToHandleClick (MapObject *obj) |
Tells whether this plugin wants to handle a mouse click event. | |
void | handleClick (MapObject *obj, const EventInfo *evt) |
Handles the left mouse click event on the IGC in the map. | |
Private Slots | |
void | coloringChanged (int i) |
One of the opened files changed its coloring. | |
Private Member Functions | |
void | fileClose (OpenedFile *f) |
Remove the opened file from the lists and notify recalculate all scales. | |
QColor | findAutomaticColor () |
Finds a least used automatic color and increments its use count. | |
void | freeAutomaticColor (QColor c) |
Decrement use count for the given automatic color. | |
Private Attributes | |
int | currentColoring |
Currently selected coloring. | |
QList< QPair< QColor, int > > | automaticColors |
QMap< QString, OpenedFile * > | opened |
MapLayerGroupInterface * | mapLayerGroup |
QVector< MapObject * > | mapObjects |
Friends | |
class | OpenedFile |
Top leve object of IGC viewer plugin.
void Updraft::IgcViewer::IgcViewer::coloringChanged | ( | int | i | ) | [private, slot] |
One of the opened files changed its coloring.
propagate this change to all of them.
void Updraft::IgcViewer::IgcViewer::deinitialize | ( | ) | [virtual] |
Called before the plugin is unloaded.
Implements Updraft::PluginBase.
void Updraft::IgcViewer::IgcViewer::fileClose | ( | OpenedFile * | f | ) | [private] |
Remove the opened file from the lists and notify recalculate all scales.
void Updraft::IgcViewer::IgcViewer::fileIdentification | ( | QStringList * | roles, |
QString * | importDirectory, | ||
const QString & | filename | ||
) |
bool Updraft::IgcViewer::IgcViewer::fileOpen | ( | const QString & | filename, |
int | roleId | ||
) | [virtual] |
Callback to open a file.
filename | full path to a file |
roleId | identification of role being opened |
Reimplemented from Updraft::PluginBase.
QColor Updraft::IgcViewer::IgcViewer::findAutomaticColor | ( | ) | [private] |
Finds a least used automatic color and increments its use count.
void Updraft::IgcViewer::IgcViewer::freeAutomaticColor | ( | QColor | c | ) | [private] |
Decrement use count for the given automatic color.
QString Updraft::IgcViewer::IgcViewer::getName | ( | ) | [virtual] |
Plugin metadata.
Implements Updraft::PluginBase.
void Updraft::IgcViewer::IgcViewer::handleClick | ( | MapObject * | obj, |
const EventInfo * | evt | ||
) | [virtual] |
Handles the left mouse click event on the IGC in the map.
Reimplemented from Updraft::PluginBase.
void Updraft::IgcViewer::IgcViewer::initialize | ( | CoreInterface * | coreInterface | ) | [virtual] |
Called after the plugin is loaded.
coreInterface | pointer to assigned CoreInterface Plugin should store this value in g_core. |
Implements Updraft::PluginBase.
bool Updraft::IgcViewer::IgcViewer::wantsToHandleClick | ( | MapObject * | obj | ) | [virtual] |
Tells whether this plugin wants to handle a mouse click event.
Reimplemented from Updraft::PluginBase.
friend class OpenedFile [friend] |
QList<QPair<QColor, int> > Updraft::IgcViewer::IgcViewer::automaticColors [private] |
int Updraft::IgcViewer::IgcViewer::currentColoring [private] |
Currently selected coloring.
QVector<MapObject*> Updraft::IgcViewer::IgcViewer::mapObjects [private] |
QMap<QString, OpenedFile*> Updraft::IgcViewer::IgcViewer::opened [private] |