diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-10-26 14:13:29 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-10-27 09:57:27 +0200 |
commit | 1b87cdadb88da0ece66c2da1a06c37420e45111c (patch) | |
tree | 0948cd6a32f378ec9a939d7fde33bfff4b910b25 /vcl | |
parent | bdd7c74a499ea550a10e47d159c2d2d80c940fc0 (diff) |
support stock text in checkboxes and radiobuttons
Change-Id: I03b2e125736b7f8a7127174a7a837760f76f8249
Reviewed-on: https://gerrit.libreoffice.org/43893
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/window/builder.cxx | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx index e8ab874696c0..9d1fedeebdf5 100644 --- a/vcl/source/window/builder.cxx +++ b/vcl/source/window/builder.cxx @@ -1263,6 +1263,11 @@ VclPtr<vcl::Window> VclBuilder::makeObject(vcl::Window *pParent, const OString & VclPtr<RadioButton> xButton = VclPtr<RadioButton>::Create(pParent, nBits); xButton->SetImageAlign(ImageAlign::Left); //default to left xWindow = xButton; + + if (::extractStock(rMap)) + { + xWindow->SetText(getStockText(extractLabel(rMap))); + } } else if (name == "GtkCheckButton") { @@ -1280,7 +1285,13 @@ VclPtr<vcl::Window> VclBuilder::makeObject(vcl::Window *pParent, const OString & if (bIsTriState) xCheckBox->SetState(TRISTATE_INDET); xCheckBox->SetImageAlign(ImageAlign::Left); //default to left + xWindow = xCheckBox; + + if (::extractStock(rMap)) + { + xWindow->SetText(getStockText(extractLabel(rMap))); + } } else if (name == "GtkSpinButton") { |