Skip to content

Commit

Permalink
Merge pull request #1740 from geopython/MetaSearch-core-merge-no-tests
Browse files Browse the repository at this point in the history
merge MetaSearch into QGIS core
  • Loading branch information
tomkralidis committed Dec 19, 2014
2 parents 984324b + e4a8fd8 commit 4b4726c
Show file tree
Hide file tree
Showing 10 changed files with 483 additions and 36 deletions.
5 changes: 5 additions & 0 deletions python/plugins/MetaSearch/AUTHORS.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
- Tom Kralidis <tomkralidis@gmail.com>
- Alexander Bruy <alexander.bruy@gmail.com>
- Maxim Dubinin <sim@gis-lab.info>
- Angelos Tzotsos <gcpp.kalxas@gmail.com>
- Richard Duivenvoorde <richard@webmapper.net>
4 changes: 2 additions & 2 deletions python/plugins/MetaSearch/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
FILE(GLOB PY_FILES *.py)
PLUGIN_INSTALL(MetaSearch . ${PY_FILES} metadata.txt)
FILE(GLOB PY_FILES __init__.py link_types.py plugin.py util.py)
PLUGIN_INSTALL(MetaSearch . ${PY_FILES} metadata.txt LICENSE.txt)

FOREACH(dir ui dialogs images resources resources/templates)
FILE(GLOB _items ${dir}/*)
Expand Down
19 changes: 19 additions & 0 deletions python/plugins/MetaSearch/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Copyright (C) 2010 NextGIS (http://nextgis.ru),
Alexander Bruy (alexander.bruy@gmail.com),
Maxim Dubinin (sim@gis-lab.info),

Copyright (C) 2014 Tom Kralidis (tomkralidis@gmail.com)

This source is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your option)
any later version.

This code is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.

You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
9 changes: 7 additions & 2 deletions python/plugins/MetaSearch/dialogs/maindialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ def __init__(self, iface):
# form inputs
self.startfrom = 0
self.maxrecords = 10
self.timeout = 10
self.constraints = []

# Servers tab
Expand Down Expand Up @@ -416,6 +417,9 @@ def search(self):
self.startfrom = 0
self.maxrecords = self.spnRecords.value()

# set timeout
self.timeout = self.spnTimeout.value()

# bbox
minx = self.leWest.text()
miny = self.leSouth.text()
Expand Down Expand Up @@ -726,7 +730,7 @@ def show_metadata(self):

try:
QApplication.setOverrideCursor(QCursor(Qt.WaitCursor))
cat = CatalogueServiceWeb(self.catalog_url)
cat = CatalogueServiceWeb(self.catalog_url, timeout=self.timeout)
cat.getrecordbyid(
[self.catalog.records[identifier].identifier])
except ExceptionReport, err:
Expand Down Expand Up @@ -798,7 +802,8 @@ def _get_csw(self):
# connect to the server
try:
QApplication.setOverrideCursor(QCursor(Qt.WaitCursor))
self.catalog = CatalogueServiceWeb(self.catalog_url)
self.catalog = CatalogueServiceWeb(self.catalog_url,
timeout=self.timeout)
return True
except ExceptionReport, err:
msg = self.tr('Error connecting to service: %s') % err
Expand Down
14 changes: 8 additions & 6 deletions python/plugins/MetaSearch/metadata.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,18 @@
name=MetaSearch Catalogue Client
description=MetaSearch is a QGIS plugin to interact with metadata catalogue services (CSW).
category=Web
version=0.3.1
version=0.3.2
qgisMinimumVersion=2.0
icon=images/MetaSearch.png
author=Tom Kralidis
email=tomkralidis@gmail.com
tags=web,catalogue,service,metadata,csw
homepage=http://geopython.github.io/MetaSearch
tracker=https://github.com/geopython/MetaSearch/issues
repository=https://github.com/geopython/MetaSearch.git
homepage=https://hub.qgis.org/projects/MetaSearch
tracker=https://hub.qgis.org/projects/MetaSearch/issues
repository=https://github.com/qgis/QGIS/tree/master/python/plugins/MetaSearch
experimental=False
deprecated=False
changelog=Version 0.3.1 (2014-09-03)
- fix packaging and translation
changelog=Version 0.3.2 (2014-11-04)
- fix message formatting
- add server timeout as plugin setting
- bump OWSLib dependency
Loading

0 comments on commit 4b4726c

Please sign in to comment.