Skip to content

Commit

Permalink
Some fixes of grass plug-in:
Browse files Browse the repository at this point in the history
* Fixed CMakeList.txt of scripts
* Fixed parsing for manual attribute of modules


git-svn-id: http://svn.osgeo.org/qgis/trunk@11193 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
rugginoso committed Jul 28, 2009
1 parent a3c7388 commit be89b8a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
9 changes: 5 additions & 4 deletions src/plugins/grass/qgsgrassmodule.cpp
Expand Up @@ -195,10 +195,11 @@ QgsGrassModule::QgsGrassModule( QgsGrassTools *tools, QString moduleName, QgisIn
QDomElement qDocElem = qDoc.documentElement();

// Read GRASS module description
QString xName = qDocElem.attribute( "manual" );
if ( xName.isEmpty() )
QString xName = qDocElem.attribute( "module" );
QString xDocName = qDocElem.attribute( "manual" );
if ( xDocName.isEmpty() )
{
xName = qDocElem.attribute( "module" );
xDocName = xName;
}

// Binary modules on windows has .exe extension
Expand Down Expand Up @@ -251,7 +252,7 @@ QgsGrassModule::QgsGrassModule( QgsGrassTools *tools, QString moduleName, QgisIn

// Create manual if available
QString gisBase = getenv( "GISBASE" );
QString manPath = gisBase + "/docs/html/" + xName + ".html";
QString manPath = gisBase + "/docs/html/" + xDocName + ".html";
QFile manFile( manPath );
if ( manFile.exists() )
{
Expand Down
4 changes: 2 additions & 2 deletions src/plugins/grass/scripts/CMakeLists.txt
@@ -1,6 +1,6 @@
IF (GRASS_NUM_VERSION GREATER 60400)
IF (GRASS_NUM_VERSION GREATER 60300)
FILE (GLOB MODULE_FILES *.py )
INSTALL (FILES ${MODULE_FILES}
DESTINATION ${QGIS_DATA_DIR}/grass/scripts
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE )
ENDIF (GRASS_NUM_VERSION GREATER 60400)
ENDIF (GRASS_NUM_VERSION GREATER 60300)

0 comments on commit be89b8a

Please sign in to comment.