diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-04-24 14:14:34 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-04-27 09:54:08 +0200 |
commit | 28fc0962b10519ab84654d189d2ad0cca8f84f95 (patch) | |
tree | ff2b008cb13f69724abfff62157c6a4e133135a2 /vcl | |
parent | 3d97c9d292d80cb82391bdb416a9c6217a8e16e4 (diff) |
weld SwLabDlg
Change-Id: I55c543776c03b1d1da0331552b98e6e281e35937
Reviewed-on: https://gerrit.libreoffice.org/53488
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/app/salvtables.cxx | 10 | ||||
-rw-r--r-- | vcl/unx/gtk3/gtk3gtkinst.cxx | 12 |
2 files changed, 22 insertions, 0 deletions
diff --git a/vcl/source/app/salvtables.cxx b/vcl/source/app/salvtables.cxx index 6ec83d72d0d8..c2f4312aa371 100644 --- a/vcl/source/app/salvtables.cxx +++ b/vcl/source/app/salvtables.cxx @@ -810,11 +810,21 @@ public: m_xNotebook->SetCurPageId(m_xNotebook->GetPageId(rIdent)); } + virtual void remove_page(const OString& rIdent) override + { + m_xNotebook->RemovePage(m_xNotebook->GetPageId(rIdent)); + } + virtual int get_n_pages() const override { return m_xNotebook->GetPageCount(); } + virtual OUString get_tab_label_text(const OString& rIdent) const override + { + return m_xNotebook->GetPageText(m_xNotebook->GetPageId(rIdent)); + } + virtual ~SalInstanceNotebook() override { m_xNotebook->SetActivatePageHdl(Link<TabControl*,void>()); diff --git a/vcl/unx/gtk3/gtk3gtkinst.cxx b/vcl/unx/gtk3/gtk3gtkinst.cxx index a204143cf5f1..134dd540f973 100644 --- a/vcl/unx/gtk3/gtk3gtkinst.cxx +++ b/vcl/unx/gtk3/gtk3gtkinst.cxx @@ -2453,6 +2453,18 @@ public: return gtk_notebook_get_n_pages(m_pNotebook); } + virtual OUString get_tab_label_text(const OString& rIdent) const override + { + gint nPage = get_page_number(rIdent); + const gchar* pStr = gtk_notebook_get_tab_label_text(m_pNotebook, gtk_notebook_get_nth_page(m_pNotebook, nPage)); + return OUString(pStr, pStr ? strlen(pStr) : 0, RTL_TEXTENCODING_UTF8); + } + + virtual void remove_page(const OString& rIdent) override + { + gtk_notebook_remove_page(m_pNotebook, get_page_number(rIdent)); + } + virtual ~GtkInstanceNotebook() override { g_signal_handler_disconnect(m_pNotebook, m_nSignalId); |