summaryrefslogtreecommitdiff
path: root/vcl/jsdialog/executor.cxx
diff options
context:
space:
mode:
authorSzymon Kłos <szymon.klos@collabora.com>2021-01-13 09:13:29 +0100
committerSzymon Kłos <szymon.klos@collabora.com>2021-01-15 08:40:01 +0100
commit72f1cbe59a90921ef74bfda5ffb7f4db6578a1af (patch)
treeeb0678580363b68b12c2107ff9cb3d84fe14bf59 /vcl/jsdialog/executor.cxx
parent8760c3036b2bcfb5021f1f4c57493de73f4859c7 (diff)
jsdialog: TreeView row activation
Change-Id: I3d2884d456f8b6fa01d2dbe6c4d2f7d9e9528e1e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109261 Tested-by: Szymon Kłos <szymon.klos@collabora.com> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Diffstat (limited to 'vcl/jsdialog/executor.cxx')
-rw-r--r--vcl/jsdialog/executor.cxx14
1 files changed, 13 insertions, 1 deletions
diff --git a/vcl/jsdialog/executor.cxx b/vcl/jsdialog/executor.cxx
index dc05c0f75f01..f2d4d61ecf61 100644
--- a/vcl/jsdialog/executor.cxx
+++ b/vcl/jsdialog/executor.cxx
@@ -219,7 +219,19 @@ bool ExecuteAction(sal_uInt64 nWindowId, const OString& rWidget, StringMap& rDat
pTreeView->select(nRow);
pTreeView->set_cursor(nRow);
LOKTrigger::trigger_changed(*pTreeView);
- //LOKTrigger::trigger_row_activated(*pTreeView);
+ return true;
+ }
+ else if (sAction == "activate")
+ {
+ OString nRowString
+ = OUStringToOString(rData["data"], RTL_TEXTENCODING_ASCII_US);
+ int nRow = std::atoi(nRowString.getStr());
+
+ pTreeView->unselect(pTreeView->get_selected_index());
+ pTreeView->select(nRow);
+ pTreeView->set_cursor(nRow);
+ LOKTrigger::trigger_changed(*pTreeView);
+ LOKTrigger::trigger_row_activated(*pTreeView);
return true;
}
else if (sAction == "expand")