Browse Source

Added Ctrl C shortcut for desktop file copy

Toby Chui 3 years ago
parent
commit
624a3efbe6

+ 1 - 0
system/share/downloadPage.html

@@ -8,6 +8,7 @@
     <link rel="stylesheet" href="../../script/skeleton/normalize.css">
     <link rel="stylesheet" href="../../script/skeleton/normalize.css">
     <link rel="stylesheet" href="../../script/skeleton/skeleton.css">
     <link rel="stylesheet" href="../../script/skeleton/skeleton.css">
     <script type="application/javascript" src="../../script/jquery.min.js"></script>
     <script type="application/javascript" src="../../script/jquery.min.js"></script>
+    <link rel="icon" type="image/png" href="../../img/public/share/share.png" />
     <style>
     <style>
 
 
         body{
         body{

+ 1 - 0
system/share/downloadPageFolder.html

@@ -8,6 +8,7 @@
     <link rel="stylesheet" href="../../script/skeleton/normalize.css">
     <link rel="stylesheet" href="../../script/skeleton/normalize.css">
     <link rel="stylesheet" href="../../script/skeleton/skeleton.css">
     <link rel="stylesheet" href="../../script/skeleton/skeleton.css">
     <script type="application/javascript" src="../../script/jquery.min.js"></script>
     <script type="application/javascript" src="../../script/jquery.min.js"></script>
+    <link rel="icon" type="image/png" href="../../img/public/share/share.png" />
     <style>
     <style>
 
 
         body{
         body{

+ 1 - 0
system/share/index.html

@@ -8,6 +8,7 @@
     <link rel="stylesheet" href="../script/skeleton/normalize.css">
     <link rel="stylesheet" href="../script/skeleton/normalize.css">
     <link rel="stylesheet" href="../script/skeleton/skeleton.css">
     <link rel="stylesheet" href="../script/skeleton/skeleton.css">
     <script type="application/javascript" src="../script/jquery.min.js"></script>
     <script type="application/javascript" src="../script/jquery.min.js"></script>
+    <link rel="icon" type="image/png" href="../img/public/share/share.png" />
     <style>
     <style>
         .bar{
         .bar{
             height: 12px;
             height: 12px;

+ 14 - 2
web/desktop.system

@@ -5585,7 +5585,7 @@
 
 
             localStorage.setItem("ao/file_system/clipboard",JSON.stringify(clipboard));
             localStorage.setItem("ao/file_system/clipboard",JSON.stringify(clipboard));
             localStorage.setItem("ao/file_system/cutmode","false");
             localStorage.setItem("ao/file_system/cutmode","false");
-
+            copyStringToClipboard(JSON.stringify(clipboard));
             hideAllContextMenus();
             hideAllContextMenus();
         }
         }
 
 
@@ -5599,7 +5599,7 @@
 
 
             localStorage.setItem("ao/file_system/clipboard",JSON.stringify(clipboard));
             localStorage.setItem("ao/file_system/clipboard",JSON.stringify(clipboard));
             localStorage.setItem("ao/file_system/cutmode","true");
             localStorage.setItem("ao/file_system/cutmode","true");
-
+            copyStringToClipboard(JSON.stringify(clipboard));
             hideAllContextMenus();
             hideAllContextMenus();
         }
         }
 
 
@@ -6560,6 +6560,18 @@
             hideAllContextMenus();
             hideAllContextMenus();
         }
         }
 
 
+        function copyStringToClipboard(content){
+            var el = document.createElement('textarea');
+            el.value = content;
+            el.setAttribute('readonly', '');
+            el.style = {position: 'absolute', left: '-9999px'};
+            document.body.appendChild(el);
+            el.select();
+            document.execCommand('copy');
+            document.body.removeChild(el);
+        }
+
+
         /*
         /*
         var screenshotBuf = [];
         var screenshotBuf = [];
         var totalFloatWindowsLeft = 0;
         var totalFloatWindowsLeft = 0;

BIN
web/img/public/share/share.png


BIN
web/img/public/share/share.psd