mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1100100 - "Downloaded file can't be opened from "Downloads" page" [r=wjohnston]
This commit is contained in:
parent
318e7ac495
commit
ab7501f93d
@ -1168,7 +1168,7 @@ public class GeckoAppShell
|
||||
}
|
||||
|
||||
final Uri uri = normalizeUriScheme(targetURI.indexOf(':') >= 0 ? Uri.parse(targetURI) : new Uri.Builder().scheme(targetURI).build());
|
||||
if (mimeType.length() > 0) {
|
||||
if (!TextUtils.isEmpty(mimeType)) {
|
||||
Intent intent = getIntentForActionString(action);
|
||||
intent.setDataAndType(uri, mimeType);
|
||||
return intent;
|
||||
@ -1184,8 +1184,10 @@ public class GeckoAppShell
|
||||
// custom handlers that would apply.
|
||||
// Start with the original URI. If we end up modifying it, we'll
|
||||
// overwrite it.
|
||||
final String extension = MimeTypeMap.getFileExtensionFromUrl(targetURI);
|
||||
final String mimeType2 = getMimeTypeFromExtension(extension);
|
||||
final Intent intent = getIntentForActionString(action);
|
||||
intent.setData(uri);
|
||||
intent.setDataAndType(uri, mimeType2);
|
||||
|
||||
if ("vnd.youtube".equals(scheme) &&
|
||||
!hasHandlersForIntent(intent) &&
|
||||
|
Loading…
Reference in New Issue
Block a user