This is an automated email from the ASF dual-hosted git repository.

hansva pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hop.git


The following commit(s) were added to refs/heads/master by this push:
     new 99c5c37038 Add button to copy log workflow/pipeline to the clipboard 
#3097 Remove unimplemented log settings button Deletes a manifest file that is 
there by mistake
     new 8839407528 Merge pull request #3135 from nadment/3097
99c5c37038 is described below

commit 99c5c37038fb614ae174cd92a8fd40dc371b1fcd
Author: Nicolas Adment <[email protected]>
AuthorDate: Thu Aug 3 20:19:04 2023 +0200

    Add button to copy log workflow/pipeline to the clipboard #3097
    Remove unimplemented log settings button
    Deletes a manifest file that is there by mistake
---
 .../pipeline/delegates/HopGuiPipelineLogDelegate.java    | 16 ++++++++--------
 .../workflow/delegates/HopGuiWorkflowLogDelegate.java    | 13 ++++++-------
 .../org/apache/hop/ui/hopgui/javaw.exe.manifest          | 10 ----------
 .../hop/ui/hopgui/messages/messages_en_US.properties     |  4 +++-
 4 files changed, 17 insertions(+), 26 deletions(-)

diff --git 
a/ui/src/main/java/org/apache/hop/ui/hopgui/file/pipeline/delegates/HopGuiPipelineLogDelegate.java
 
b/ui/src/main/java/org/apache/hop/ui/hopgui/file/pipeline/delegates/HopGuiPipelineLogDelegate.java
index 6f8889725e..afcf670743 100644
--- 
a/ui/src/main/java/org/apache/hop/ui/hopgui/file/pipeline/delegates/HopGuiPipelineLogDelegate.java
+++ 
b/ui/src/main/java/org/apache/hop/ui/hopgui/file/pipeline/delegates/HopGuiPipelineLogDelegate.java
@@ -55,7 +55,7 @@ public class HopGuiPipelineLogDelegate {
   private static final String GUI_PLUGIN_TOOLBAR_PARENT_ID = 
"HopGuiPipelineLogDelegate-ToolBar";
   public static final String TOOLBAR_ICON_CLEAR_LOG_VIEW = 
"ToolbarIcon-10000-ClearLog";
   public static final String TOOLBAR_ICON_SHOW_ERROR_LINES = 
"ToolbarIcon-10010-ShowErrorLines";
-  public static final String TOOLBAR_ICON_LOG_SETTINGS = 
"ToolbarIcon-10020-LogSettings";
+  public static final String TOOLBAR_ICON_LOG_COPY_TO_CLIPBOARD = 
"ToolbarIcon-10020-LogCopyToClipboard";
   public static final String TOOLBAR_ICON_LOG_PAUSE_RESUME = 
"ToolbarIcon-10030-LogPauseResume";
 
   private HopGuiPipelineGraph pipelineGraph;
@@ -209,14 +209,14 @@ public class HopGuiPipelineLogDelegate {
 
   @GuiToolbarElement(
       root = GUI_PLUGIN_TOOLBAR_PARENT_ID,
-      id = TOOLBAR_ICON_LOG_SETTINGS,
-      // label = "PipelineLog.Button.LogSettings",
-      toolTip = "i18n:org.apache.hop.ui.hopgui:PipelineLog.Button.LogSettings",
-      image = "ui/images/settings.svg")
-  public void showLogSettings() {
-    // TODO: implement or rethink
+      id = TOOLBAR_ICON_LOG_COPY_TO_CLIPBOARD,
+      toolTip = 
"i18n:org.apache.hop.ui.hopgui:PipelineLog.Button.LogCopyToClipboard",
+      image = "ui/images/copy.svg") 
+  public void copyToClipboard() {
+    GuiResource.getInstance().toClipboard(pipelineLogText.getText());
   }
-
+  
+  
   @GuiToolbarElement(
       root = GUI_PLUGIN_TOOLBAR_PARENT_ID,
       id = TOOLBAR_ICON_SHOW_ERROR_LINES,
diff --git 
a/ui/src/main/java/org/apache/hop/ui/hopgui/file/workflow/delegates/HopGuiWorkflowLogDelegate.java
 
b/ui/src/main/java/org/apache/hop/ui/hopgui/file/workflow/delegates/HopGuiWorkflowLogDelegate.java
index 8c51541d95..d78be3ea8b 100644
--- 
a/ui/src/main/java/org/apache/hop/ui/hopgui/file/workflow/delegates/HopGuiWorkflowLogDelegate.java
+++ 
b/ui/src/main/java/org/apache/hop/ui/hopgui/file/workflow/delegates/HopGuiWorkflowLogDelegate.java
@@ -55,7 +55,7 @@ public class HopGuiWorkflowLogDelegate {
   private static final String GUI_PLUGIN_TOOLBAR_PARENT_ID = 
"HopGuiWorkflowLogDelegate-ToolBar";
   public static final String TOOLBAR_ICON_CLEAR_LOG_VIEW = 
"ToolbarIcon-10000-ClearLog";
   public static final String TOOLBAR_ICON_SHOW_ERROR_LINES = 
"ToolbarIcon-10010-ShowErrorLines";
-  public static final String TOOLBAR_ICON_LOG_SETTINGS = 
"ToolbarIcon-10020-LogSettings";
+  public static final String TOOLBAR_ICON_LOG_COPY_TO_CLIPBOARD = 
"ToolbarIcon-10020-LogCopyToClipboard";
   public static final String TOOLBAR_ICON_LOG_PAUSE_RESUME = 
"ToolbarIcon-10030-LogPauseResume";
 
   private HopGui hopGui;
@@ -187,12 +187,11 @@ public class HopGuiWorkflowLogDelegate {
 
   @GuiToolbarElement(
       root = GUI_PLUGIN_TOOLBAR_PARENT_ID,
-      id = TOOLBAR_ICON_LOG_SETTINGS,
-      // label = "WorkflowLog.Button.LogSettings",
-      toolTip = "i18n:org.apache.hop.ui.hopgui:WorkflowLog.Button.LogSettings",
-      image = "ui/images/settings.svg")
-  public void showLogSettings() {
-    // TODO: implement or rethink
+      id = TOOLBAR_ICON_LOG_COPY_TO_CLIPBOARD,
+      toolTip = 
"i18n:org.apache.hop.ui.hopgui:WorkflowLog.Button.LogCopyToClipboard",
+      image = "ui/images/copy.svg")
+  public void copyToClipboard() {
+    GuiResource.getInstance().toClipboard(workflowLogText.getText());
   }
 
   @GuiToolbarElement(
diff --git a/ui/src/main/resources/org/apache/hop/ui/hopgui/javaw.exe.manifest 
b/ui/src/main/resources/org/apache/hop/ui/hopgui/javaw.exe.manifest
deleted file mode 100644
index 356366466c..0000000000
--- a/ui/src/main/resources/org/apache/hop/ui/hopgui/javaw.exe.manifest
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
-       <assemblyIdentity version="1.0.0.0" processorArchitecture="X86" 
name="SWT.javaw" type="win32"/>
-       <description>Standard Widget Toolkit</description>
-       <dependency>
-               <dependentAssembly>
-                       <assemblyIdentity type="win32" 
name="Microsoft.Windows.Common-Controls" version="6.0.0.0" 
processorArchitecture="X86" publicKeyToken="6595b64144ccf1df" language="*"/>
-               </dependentAssembly>
-       </dependency>
-</assembly>
diff --git 
a/ui/src/main/resources/org/apache/hop/ui/hopgui/messages/messages_en_US.properties
 
b/ui/src/main/resources/org/apache/hop/ui/hopgui/messages/messages_en_US.properties
index 10bf8a1a0f..6d9755d8d1 100644
--- 
a/ui/src/main/resources/org/apache/hop/ui/hopgui/messages/messages_en_US.properties
+++ 
b/ui/src/main/resources/org/apache/hop/ui/hopgui/messages/messages_en_US.properties
@@ -205,7 +205,8 @@ PipelineGraph.ViewOutput.OutputDialog.Last.Text=Last 
(REVERSE ORDER!)
 PipelineGraph.ViewOutput.OutputDialog.OutputRows.Text=output rows of transform 
{0}
 PipelineGraph.ViewOutput.OutputDialog.Random.Text=Random 
 PipelineLog.Button.ClearLog=\ &Clear log 
-PipelineLog.Button.LogSettings=\ &Log settings 
+PipelineLog.Button.LogSettings=\ &Log settings
+PipelineLog.Button.LogCopyToClipboard=Copy pipeline log to clipboard 
 PipelineLog.Button.ShowErrorLines=\ &Show error lines 
 PipelineLog.Button.ShowOnlyActiveTransforms=Hide inactive
 PipelineLog.Button.ShowOnlySelectedTransforms=Show only selected transforms
@@ -253,6 +254,7 @@ PipelineLog.System.EXCEPTION=EXCEPTION
 WorkflowGraph.Dialog.HopCausesLoop.Message=This hop causes a loop.  This is 
not allowed.
 WorkflowGraph.Dialog.HopCausesLoop.Title=Loop\!
 WorkflowLog.Button.LogSettings=Log settings
+WorkflowLog.Button.LogCopyToClipboard=Copy workflow log to clipboard
 WorkflowLog.Button.Pause=Pause workflow log
 WorkflowLog.Button.ShowErrorLines=Show error lines
 WorkflowLog.Dialog.SaveJobBeforeRunning.Message=Please save the workflow 
before running it.

Reply via email to