Use SVG previews for public sharing

Fixes https://github.com/owncloud/core/pull/11367#issuecomment-57306037 and https://github.com/owncloud/core/issues/9218

@georgehrke @jancborchardt @icewind1991 Please test - THX.
@karlitschek Needs a backport to stable6 and stable7 - otherwise public sharing is somewhat broken for files without preview provider.
:+1: for ternary operator