diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2015-07-08 20:35:21 +0200 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2015-07-12 18:56:48 +0200 |
commit | 7cad6b12c801a21b2401958c60625a50320fb5c7 (patch) | |
tree | 117e94a102246cbc1050c64875349ff377762481 | |
parent | 498e03c2a32ec0250fa2e7cb07f7fc3425212e58 (diff) |
[API CHANGE] add way to get XSidebar from XSidebarProvider
Change-Id: I9fcf1cffa70eac6fec228ca4a9d4d32783295f21
-rw-r--r-- | include/sfx2/sidebar/UnoSidebar.hxx | 4 | ||||
-rw-r--r-- | offapi/com/sun/star/ui/XSidebarProvider.idl | 6 | ||||
-rw-r--r-- | sfx2/source/sidebar/UnoSidebar.cxx | 6 |
3 files changed, 16 insertions, 0 deletions
diff --git a/include/sfx2/sidebar/UnoSidebar.hxx b/include/sfx2/sidebar/UnoSidebar.hxx index 6c154c0840a5..9cbb4e1fcfb2 100644 --- a/include/sfx2/sidebar/UnoSidebar.hxx +++ b/include/sfx2/sidebar/UnoSidebar.hxx @@ -14,6 +14,7 @@ #include <sfx2/dllapi.h> #include <com/sun/star/frame/XFrame.hpp> #include <com/sun/star/ui/XSidebarProvider.hpp> +#include <com/sun/star/ui/XSidebar.hpp> #include <com/sun/star/awt/XWindow2.hpp> @@ -56,6 +57,9 @@ public: virtual css::uno::Reference<css::ui::XDecks> SAL_CALL getDecks() throw(css::uno::RuntimeException, std::exception) SAL_OVERRIDE; + virtual css::uno::Reference<css::ui::XSidebar> SAL_CALL getSidebar() + throw(css::uno::RuntimeException, std::exception) SAL_OVERRIDE; + }; #endif diff --git a/offapi/com/sun/star/ui/XSidebarProvider.idl b/offapi/com/sun/star/ui/XSidebarProvider.idl index 370925ec8084..5786550df2d8 100644 --- a/offapi/com/sun/star/ui/XSidebarProvider.idl +++ b/offapi/com/sun/star/ui/XSidebarProvider.idl @@ -14,6 +14,7 @@ #include <com/sun/star/frame/XFrame.idl> #include <com/sun/star/awt/XWindow2.idl> +#include <com/sun/star/ui/XSidebar.idl> #include <com/sun/star/ui/XDecks.idl> @@ -52,6 +53,11 @@ interface XSidebarProvider: com::sun::star::uno::XInterface </ul> */ void showDecks([in] boolean bVisible); + + /** + * Returns the sidebar object + */ + com::sun::star::ui::XSidebar getSidebar(); } ; } ; } ; } ; } ; diff --git a/sfx2/source/sidebar/UnoSidebar.cxx b/sfx2/source/sidebar/UnoSidebar.cxx index 28de260f5a50..cfaebbf50238 100644 --- a/sfx2/source/sidebar/UnoSidebar.cxx +++ b/sfx2/source/sidebar/UnoSidebar.cxx @@ -98,5 +98,11 @@ uno::Reference<ui::XDecks> SAL_CALL SfxUnoSidebar::getDecks() return decks; } +uno::Reference<ui::XSidebar> SAL_CALL SfxUnoSidebar::getSidebar() + throw (uno::RuntimeException, std::exception) +{ + return getSidebarController(); +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |