patch-src_app_qgisapp_cpp 1.4 KB

12345678910111213141516171819202122232425262728293031323334
  1. $OpenBSD: patch-src_app_qgisapp_cpp,v 1.19 2017/05/31 11:49:28 landry Exp $
  2. Fix paths to docs
  3. Index: src/app/qgisapp.cpp
  4. --- src/app/qgisapp.cpp.orig
  5. +++ src/app/qgisapp.cpp
  6. @@ -1712,7 +1712,7 @@ void QgisApp::createActions()
  7. mActionReportaBug->setShortcut( QString() );
  8. #endif
  9. - mActionHelpContents->setEnabled( QFileInfo( QgsApplication::pkgDataPath() + "/doc/index.html" ).exists() );
  10. + mActionHelpContents->setEnabled( QFileInfo( QgsApplication::pkgDataPath() + "/../doc/qgis/index.html" ).exists() );
  11. connect( mActionHelpContents, SIGNAL( triggered() ), this, SLOT( helpContents() ) );
  12. connect( mActionHelpAPI, SIGNAL( triggered() ), this, SLOT( apiDocumentation() ) );
  13. @@ -9160,7 +9160,7 @@ void QgisApp::helpContents()
  14. void QgisApp::apiDocumentation()
  15. {
  16. - if ( QFileInfo( QgsApplication::pkgDataPath() + "/doc/api/index.html" ).exists() )
  17. + if ( QFileInfo( QgsApplication::pkgDataPath() + "/../doc/qgis/api/index.html" ).exists() )
  18. {
  19. openURL( "api/index.html" );
  20. }
  21. @@ -9189,7 +9189,7 @@ void QgisApp::openURL( QString url, bool useQgisDocDir
  22. // open help in user browser
  23. if ( useQgisDocDirectory )
  24. {
  25. - url = "file://" + QgsApplication::pkgDataPath() + "/doc/" + url;
  26. + url = "file://" + QgsApplication::pkgDataPath() + "/../doc/qgis/" + url;
  27. }
  28. #ifdef Q_OS_MACX
  29. /* Use Mac OS X Launch Services which uses the user's default browser