diff options
author | Caolán McNamara <caolanm@redhat.com> | 2020-06-20 16:01:07 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2020-06-23 12:50:00 +0200 |
commit | 5bbd8aecad3d2cc97c075490ef27aecc9180ef99 (patch) | |
tree | 6c5c2084d81ac5930bddb1668c86a6a1f322072f /vcl/jsdialog | |
parent | 9d5e36c216d01a2cc0b2aefa801bb96ddb6eb199 (diff) |
most of jsdialogbuilder is not used outside vcl
so split it into the bit that is needed and just include that.
add missing license headers
Change-Id: I875f91176e6881e830fee6a58368d0b28ce9a0f7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96774
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Diffstat (limited to 'vcl/jsdialog')
-rw-r--r-- | vcl/jsdialog/jsdialogbuilder.cxx | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/vcl/jsdialog/jsdialogbuilder.cxx b/vcl/jsdialog/jsdialogbuilder.cxx index d7f35b7d6039..fa7f25d33c00 100644 --- a/vcl/jsdialog/jsdialogbuilder.cxx +++ b/vcl/jsdialog/jsdialogbuilder.cxx @@ -7,7 +7,7 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -#include <vcl/jsdialog/jsdialogbuilder.hxx> +#include <jsdialog/jsdialogbuilder.hxx> #include <sal/log.hxx> #include <boost/property_tree/json_parser.hpp> #include <comphelper/lok.hxx> @@ -88,12 +88,13 @@ std::map<vcl::LOKWindowId, WidgetMap>& JSInstanceBuilder::GetLOKWeldWidgetsMap() return s_aLOKWeldBuildersMap; } -weld::Widget* JSInstanceBuilder::FindWeldWidgetsMap(vcl::LOKWindowId nWindowId, - const OString& rWidget) +namespace jsdialog { - const auto it = GetLOKWeldWidgetsMap().find(nWindowId); +weld::Widget* FindWeldWidgetsMap(vcl::LOKWindowId nWindowId, const OString& rWidget) +{ + const auto it = JSInstanceBuilder::GetLOKWeldWidgetsMap().find(nWindowId); - if (it != GetLOKWeldWidgetsMap().end()) + if (it != JSInstanceBuilder::GetLOKWeldWidgetsMap().end()) { auto widgetIt = it->second.find(rWidget); if (widgetIt != it->second.end()) @@ -102,6 +103,7 @@ weld::Widget* JSInstanceBuilder::FindWeldWidgetsMap(vcl::LOKWindowId nWindowId, return nullptr; } +} void JSInstanceBuilder::InsertWindowToMap(int nWindowId) { |