mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-05-07 14:56:06 +02:00
Fix ScreenshotMetadata drag drop (#843)
Provide the full path to dragEnterCef instead of only the file name.
This commit is contained in:
@@ -16,9 +16,9 @@ namespace VRCX
|
|||||||
{
|
{
|
||||||
public bool OnDragEnter(IWebBrowser chromiumWebBrowser, IBrowser browser, IDragData dragData, DragOperationsMask mask)
|
public bool OnDragEnter(IWebBrowser chromiumWebBrowser, IBrowser browser, IDragData dragData, DragOperationsMask mask)
|
||||||
{
|
{
|
||||||
if (dragData.IsFile && dragData.FileNames != null && dragData.FileNames.Count > 0)
|
if (dragData.IsFile && dragData.FilePaths != null && dragData.FilePaths.Count > 0)
|
||||||
{
|
{
|
||||||
string file = dragData.FileNames[0];
|
string file = dragData.FilePaths[0];
|
||||||
if (!file.EndsWith(".png") && !file.EndsWith(".jpg") && !file.EndsWith(".jpeg"))
|
if (!file.EndsWith(".png") && !file.EndsWith(".jpg") && !file.EndsWith(".jpeg"))
|
||||||
{
|
{
|
||||||
dragData.Dispose();
|
dragData.Dispose();
|
||||||
@@ -26,7 +26,7 @@ namespace VRCX
|
|||||||
}
|
}
|
||||||
|
|
||||||
// forgive me father for i have sinned once again
|
// forgive me father for i have sinned once again
|
||||||
AppApi.Instance.ExecuteAppFunction("dragEnterCef", dragData.FileNames[0]);
|
AppApi.Instance.ExecuteAppFunction("dragEnterCef", file);
|
||||||
dragData.Dispose();
|
dragData.Dispose();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user