Register Marble app, part & thumbnailer for application/vnd.geo+json

Summary:
Don't be shy, tell the system that Marble has a plugin for handling geojson
:)

Test Plan:
Created a sample file with the example from en.wikipedia.org/wiki/GeoJSON
My shared-mime-info has application/vnd.geo+json already (added in Oct
2015). Installing with the patch and triggering kbuildsycoca5, Marble is
called as handler when clicking on the sample file in Dlphin as well as does
the  thumbnailer show a preview (need enabling in Dolphin settings as usual)

Reviewers: rahn, nienhueser

Reviewed By: nienhueser

Projects: #marble

Differential Revision: https://phabricator.kde.org/D1492
parent 6ba6788a
......@@ -10,3 +10,21 @@ set( json_SRCS JsonRunner.cpp JsonPlugin.cpp JsonParser.cpp )
set( JsonPlugin_LIBS Qt5::Script )
marble_add_plugin( JsonPlugin ${json_SRCS} )
if(WIN32 OR APPLE)
# nothing to do
else()
install(FILES marble_geojson.desktop DESTINATION ${APPS_INSTALL_DIR})
endif()
set(KDE_SKIP_UNINSTALL_TARGET ON CACHE BOOL "KDE uninstall target must be disabled")
find_package(ECM QUIET)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH})
if(ECM_FOUND)
include(KDEInstallDirs)
endif()
macro_optional_find_package(KF5 QUIET COMPONENTS KIO)
if(KF5_FOUND)
install(FILES marble_part_geojson.desktop DESTINATION ${SERVICES_INSTALL_DIR})
install(FILES marble_thumbnail_geojson.desktop DESTINATION ${SERVICES_INSTALL_DIR})
endif()
[Desktop Entry]
Type=Application
TryExec=marble
Exec=marble %F
Name=Marble
NoDisplay=true
GenericName=Virtual Globe
MimeType=application/vnd.geo+json;
Icon=marble
Terminal=false
Categories=Qt;KDE;Education;Geography;
[Desktop Entry]
Type=Service
Name=Marble Part
MimeType=application/vnd.geo+json;
X-KDE-ServiceTypes=Browser/View,KParts/ReadOnlyPart
X-KDE-Library=libmarble_part
Icon=marble
[Desktop Entry]
Type=Service
Name=GeoJSON Geographic Data
X-KDE-ServiceTypes=ThumbCreator
MimeType=application/vnd.geo+json;
X-KDE-Library=marblethumbnail
CacheThumbnail=true
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment