Skip to content

Commit

Permalink
process selected text from output, if selection has been made by user.
Browse files Browse the repository at this point in the history
…close #2671
  • Loading branch information
j-dimension committed Nov 16, 2024
1 parent b47ceac commit ba4f00c
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1314,9 +1314,13 @@ private void cmdCopyActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST
private void cmdProcessOutputActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cmdProcessOutputActionPerformed
if(this.inputAdapter instanceof AssistantFlowAdapter && this.result!=null) {

String resultText=this.taResult.getText();
if(taResult.getSelectedText()!=null)
resultText=taResult.getSelectedText();

for (OutputData o : this.result.getResponse().getOutputData()) {
if (o.getType().equalsIgnoreCase(OutputData.TYPE_STRING)) {
o.setStringData(this.taResult.getText());
o.setStringData(resultText);
}
}

Expand Down

0 comments on commit ba4f00c

Please sign in to comment.