lucadelu/OGR2Layers — pull request #4 by simone-f (2013-12-04 20:55:05+00:00)
Title: Substitute deprecated functions in writeShape()

While trying to use OGR2Layers Plugin with a spatialite layer as input, these warnings are shown:
"QgsCoordinateReferenceSystem" object has not attribute "createFromEpsg".
"type object 'QgsVectorFileWriter' has no attribute 'writeAsshapeFile'"
because the two functions are deprecated in QGIS v2.

This pull request fixes them.

More info:
http://hub.qgis.org/wiki/quantum-gis/API_changes_for_version_20#QgsCoordinateReferenceSystem
http://hub.qgis.org/wiki/quantum-gis/API_changes_for_version_20#QgsVectorFileWriter
https://github.com/sourcepole/qgis-openlayers-plugin/blob/master/openlayers/openlayers_plugin.py