mirror of
https://github.com/QL-Win/QuickLook.git
synced 2025-09-14 20:29:07 +00:00
@@ -66,8 +66,8 @@ namespace QuickLook.Plugin.TextViewer
|
|||||||
return true;
|
return true;
|
||||||
|
|
||||||
// if there is a matched highlighting scheme (by file extension), treat it as a plain text file
|
// if there is a matched highlighting scheme (by file extension), treat it as a plain text file
|
||||||
if (HighlightingManager.Instance.GetDefinitionByExtension(Path.GetExtension(path)) != null)
|
//if (HighlightingManager.Instance.GetDefinitionByExtension(Path.GetExtension(path)) != null)
|
||||||
return true;
|
// return true;
|
||||||
|
|
||||||
// otherwise, read the first 16KB, check if we can get something.
|
// otherwise, read the first 16KB, check if we can get something.
|
||||||
using (var s = new FileStream(path, FileMode.Open, FileAccess.Read, FileShare.ReadWrite))
|
using (var s = new FileStream(path, FileMode.Open, FileAccess.Read, FileShare.ReadWrite))
|
||||||
|
@@ -123,7 +123,9 @@ namespace QuickLook.Plugin.VideoViewer
|
|||||||
var tracks = media.GetTracks();
|
var tracks = media.GetTracks();
|
||||||
var video = tracks.FirstOrDefault(mt => mt.Type == TrackType.Video) as VideoTrack;
|
var video = tracks.FirstOrDefault(mt => mt.Type == TrackType.Video) as VideoTrack;
|
||||||
|
|
||||||
size = video == null ? Size.Empty : new Size(video.Width, video.Height);
|
size = video == null
|
||||||
|
? Size.Empty
|
||||||
|
: new Size(Math.Max(1366, video.Width), Math.Max(768, video.Height));
|
||||||
|
|
||||||
return video != null;
|
return video != null;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user