Skip to content

Commit

Permalink
File transfer updates.
Browse files Browse the repository at this point in the history
  • Loading branch information
bitbound committed Apr 29, 2020
1 parent e39af04 commit 4215d16
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 9 deletions.
5 changes: 3 additions & 2 deletions ScreenCast.Core/Services/FileTransferService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -165,12 +165,13 @@ private void ShowTransferComplete()
if (EnvironmentHelper.IsWindows)
{
messageBoxPending = true;
var result = Win32Interop.ShowMessageBox(IntPtr.Zero,
var result = Win32Interop.ShowMessageBox(User32.GetDesktopWindow(),
"File transfer complete. Show folder?",
"Transfer Complete",
User32.MessageBoxType.MB_YESNO |
User32.MessageBoxType.MB_ICONINFORMATION |
User32.MessageBoxType.MB_TOPMOST);
User32.MessageBoxType.MB_TOPMOST |
User32.MessageBoxType.MB_SYSTEMMODAL);

if (result == User32.MessageBoxResult.IDYES)
{
Expand Down
4 changes: 2 additions & 2 deletions Server/Pages/RemoteControl.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,8 @@
</div>

<div id="fileTransferDiv" hidden="hidden">
<span id="fileTransferNameSpan" class="mr-1" style="vertical-align: middle;"></span>
<progress id="fileTransferProgress" style="vertical-align: middle;"></progress>
<span id="fileTransferNameSpan" class="mr-1 font-weight-bold" style="vertical-align: middle;"></span>
<progress id="fileTransferProgress" style="vertical-align: middle; width: 100%"></progress>
</div>

<footer>
Expand Down
5 changes: 4 additions & 1 deletion Server/Server.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,13 @@

<ItemGroup>
<Compile Remove="Areas\Identity\Services\**" />
<Compile Remove="wwwroot\lib\%40types\popper\**" />
<Content Remove="Areas\Identity\Services\**" />
<Content Remove="wwwroot\lib\%40types\popper\**" />
<EmbeddedResource Remove="Areas\Identity\Services\**" />
<EmbeddedResource Remove="wwwroot\lib\%40types\popper\**" />
<None Remove="Areas\Identity\Services\**" />
<None Remove="wwwroot\lib\%40types\popper\**" />
</ItemGroup>

<ItemGroup>
Expand Down Expand Up @@ -137,7 +141,6 @@
<TypeScriptCompile Include="wwwroot\lib\%40types\jquery\legacy.d.ts" />
<TypeScriptCompile Include="wwwroot\lib\%40types\jquery\misc.d.ts" />
<TypeScriptCompile Include="wwwroot\lib\%40types\sizzle\index.d.ts" />
<TypeScriptCompile Include="wwwroot\lib\%40types\popper\index.d.ts" />
<TypeScriptCompile Include="wwwroot\scripts\Chat.ts" />
<TypeScriptCompile Include="wwwroot\scripts\CommandCompletion.ts" />
<TypeScriptCompile Include="wwwroot\scripts\Commands\BashCommands.ts" />
Expand Down
2 changes: 1 addition & 1 deletion Server/wwwroot/lib/@types/bootstrap/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

/// <reference types="jquery"/>

import * as Popper from "popper.js";
import * as Popper from "../popper.js/index";

export as namespace Bootstrap;

Expand Down
2 changes: 1 addition & 1 deletion Server/wwwroot/scripts/RemoteControl/FileUploader.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Server/wwwroot/scripts/RemoteControl/FileUploader.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Server/wwwroot/scripts/RemoteControl/FileUploader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export async function UploadFiles(fileList: FileList) {

try {
for (var i = 0; i < fileList.length; i++) {
FileTransferNameSpan.innerHTML = fileList[i].name + ":";
FileTransferNameSpan.innerHTML = fileList[i].name;
var buffer = await fileList[i].arrayBuffer();
await MainRc.MessageSender.SendFile(new Uint8Array(buffer), fileList[i].name);
}
Expand Down

0 comments on commit 4215d16

Please sign in to comment.