summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vcl/unx/gtk3/gtk3gtkinst.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/vcl/unx/gtk3/gtk3gtkinst.cxx b/vcl/unx/gtk3/gtk3gtkinst.cxx
index c5eca37b025b..5ce282bd5362 100644
--- a/vcl/unx/gtk3/gtk3gtkinst.cxx
+++ b/vcl/unx/gtk3/gtk3gtkinst.cxx
@@ -1479,6 +1479,11 @@ namespace
}
}
+static OString MapToGtkAccelerator(const OUString &rStr)
+{
+ return OUStringToOString(rStr.replaceFirst("~", "_"), RTL_TEXTENCODING_UTF8);
+}
+
class GtkInstanceDialog : public GtkInstanceWindow, public virtual weld::Dialog
{
private:
@@ -1550,7 +1555,7 @@ public:
virtual void add_button(const OUString& rText, int nResponse) override
{
- gtk_dialog_add_button(m_pDialog, OUStringToOString(rText, RTL_TEXTENCODING_UTF8).getStr(), VclToGtk(nResponse));
+ gtk_dialog_add_button(m_pDialog, MapToGtkAccelerator(rText).getStr(), VclToGtk(nResponse));
}
virtual void set_default_response(int nResponse) override
@@ -1609,11 +1614,6 @@ public:
}
};
-static OString MapToGtkAccelerator(const OUString &rStr)
-{
- return OUStringToOString(rStr.replaceFirst("~", "_"), RTL_TEXTENCODING_UTF8);
-}
-
class GtkInstanceFrame : public GtkInstanceContainer, public virtual weld::Frame
{
private: