Skip to content
Permalink
Browse files

Fix relative paths for offline editing

  • Loading branch information
m-kuhn committed Jul 11, 2016
1 parent d5128d2 commit 1a7a87bc703486637ff119209175fc856da61cac
Showing with 3 additions and 2 deletions.
  1. +3 −2 src/core/qgsofflineediting.cpp
@@ -181,7 +181,7 @@ bool QgsOfflineEditing::convertToOfflineProject( const QString& offlineDataPath,
projectTitle += " (offline)";
QgsProject::instance()->setTitle( projectTitle );

QgsProject::instance()->writeEntry( PROJECT_ENTRY_SCOPE_OFFLINE, PROJECT_ENTRY_KEY_OFFLINE_DB_PATH, dbPath );
QgsProject::instance()->writeEntry( PROJECT_ENTRY_SCOPE_OFFLINE, PROJECT_ENTRY_KEY_OFFLINE_DB_PATH, QgsProject::instance()->writePath( dbPath ) );

return true;
}
@@ -915,7 +915,8 @@ sqlite3* QgsOfflineEditing::openLoggingDb()
QString dbPath = QgsProject::instance()->readEntry( PROJECT_ENTRY_SCOPE_OFFLINE, PROJECT_ENTRY_KEY_OFFLINE_DB_PATH );
if ( !dbPath.isEmpty() )
{
int rc = sqlite3_open( dbPath.toUtf8().constData(), &db );
QString absoluteDbPath = QgsProject::instance()->readPath( dbPath );
int rc = sqlite3_open( absoluteDbPath.toUtf8().constData(), &db );
if ( rc != SQLITE_OK )
{
showWarning( tr( "Could not open the spatialite logging database" ) );

0 comments on commit 1a7a87b

Please sign in to comment.
You can’t perform that action at this time.