[Program Plugin] Support .url file#1476
Conversation
|
What if the .url file is not a steam shortcut but a internet page? Obviously we don't want it in Program. |
|
It is possible to filter by protocol. But to be honest I've been adding url to Program for months without this patch and never have a thought about it. My brain just filter them out. |
|
The above screen shot is not this pr, but only preview pr and suffix are set.
https://developer.valvesoftware.com/wiki/Steam_browser_protocol It's my first time seeing this url file type, and I confirmed that usually use it on Steam. The other files were link files to websites that most would not use. (docs in web or Game services that require website login) Considering the high number of downloads of the Steam plug-in, it is certainly inconvenient that the Steam game cannot be searched in windows. Although the number of downloads of the Steam Plug-in will decrease, it seems to good to be provided as a default. (There may be overlapping results with existing Steam Plug-in users.) |
|
Personally I don't think this is a good idea. Not the idea of supporting indexing steam games itself, but the way you manage these.url files. You need to put these .url files in a folder and manually manage them. Steam only let you add shortcuts to desktop iirc. If you don't want all these shortcuts on your desktop you need to cut them to somewhere else. |
|
Stream also create url files in the start menu. You don't have to manually do anything. Even windows builtin search can find these files, and this pr bring Flow to parity with it which is the bare minimum in term of capabilities. My main issue with the steam plugin is it doesn't score the results, so you must use a trigger word which is very inconvenient. |
It's my problem then. I just found that I never check the "Add to start menu" checkbox.
Seems related to Garulf/Steam-Search#30. |
|
I'm aware of the issue and have discussed with Garulf about it. While it is simple to give the results a score boost, it is not easy to give them a score that play well with other result since fuzzy match is not accessible in python. Scoring is also not well documented in general. |
I have a PR in the works that'll allow Python plugins to use Flow Launchers Fuzzy matching. |
really??? how's that possible🤔 |
Actually not hard to implement. I just haven't decided on the design. |
|
@VictoriousRaptor Error. |
taooceros
left a comment
There was a problem hiding this comment.
LGTM, but there's a few things to check.
| { | ||
| // will get here either when icoPath has value\icon delegate is null\when had exception in delegate | ||
| image = ImageLoader.Load(imagePath); | ||
| image = ImageLoader.Load(imagePath, loadFullImage); |
There was a problem hiding this comment.
The loadFullImage will not do anything actually. We may want to change how cache work later. pending to be do in #1351.
| } | ||
|
|
||
| var iconPath = urlSection?["IconFile"]; | ||
| if (iconPath != null && Path.GetExtension(iconPath).Equals(".ico", StringComparison.OrdinalIgnoreCase)) |
There was a problem hiding this comment.
Why do we need to check the extension? What may be the extension? jpg or png? Though those two are both supported I believe?
|
|
||
| [JsonIgnore] | ||
| public Dictionary<string, bool> BuiltinProtocolsStatus { get; set; } = new Dictionary<string, bool>{ | ||
| { $"steam://run/{SuffixSeparator}steam://rungameid/", true }, { "com.epicgames.launcher://apps/", true }, { $"http://{SuffixSeparator}https://", false} |
There was a problem hiding this comment.
I somehow feel that we don't use the functionality of Dictionary. Consider using List<(string,bool)> instead? Thoug this is fine.




Notably Steam use .url for games shortcut.
What's the PR
Test Cases