예제 #1
0
YoursPlugin::YoursPlugin( QObject *parent ) :
    RoutingRunnerPlugin( parent )
{
    setSupportedCelestialBodies( QStringList() << "earth" );
    setCanWorkOffline( false );
    setStatusMessage( tr ( "This service requires an Internet connection." ) );
}
예제 #2
0
RoutinoPlugin::RoutinoPlugin( QObject *parent ) : RunnerPlugin( parent )
{
    setCapabilities( Routing );
    setSupportedCelestialBodies( QStringList() << "earth" );
    setCanWorkOffline( true );
    setName( tr( "Routino" ) );
    setNameId( "routino" );
    setDescription( tr( "Retrieves routes from routino" ) );
    setGuiString( tr( "Routino Routing" ) );
}
예제 #3
0
LocalOsmSearchPlugin::LocalOsmSearchPlugin( QObject *parent ) :
    SearchRunnerPlugin( parent ),
    m_databaseFiles()
{
    setSupportedCelestialBodies(QStringList(QStringLiteral("earth")));
    setCanWorkOffline( true );

    QString const path = MarbleDirs::localPath() + QLatin1String("/maps/earth/placemarks/");
    QFileInfo pathInfo( path );
    if ( !pathInfo.exists() ) {
        QDir("/").mkpath( pathInfo.absolutePath() );
        pathInfo.refresh();
    }
    if ( pathInfo.exists() ) {
        m_watcher.addPath( path );
    }
    connect( &m_watcher, SIGNAL(directoryChanged(QString)), this, SLOT(updateDirectory(QString)) );
    connect( &m_watcher, SIGNAL(fileChanged(QString)), this, SLOT(updateFile(QString)) );

    updateDatabase();
}
예제 #4
0
NominatimPlugin::NominatimPlugin( QObject *parent ) :
    SearchRunnerPlugin( parent )
{
    setSupportedCelestialBodies( QStringList() << "earth" );
    setCanWorkOffline( false );
}
예제 #5
0
RoutinoPlugin::RoutinoPlugin( QObject *parent ) :
    RoutingRunnerPlugin( parent )
{
    setSupportedCelestialBodies( QStringList() << "earth" );
    setCanWorkOffline( true );
}