sfx2/source/sidebar/Theme.cxx | 78 ++---------------------------------------- 1 file changed, 4 insertions(+), 74 deletions(-)
New commits: commit 7840d0ed4deb047f5977f258deb69d0a4ddb9918 Author: Matthias Seidel <msei...@apache.org> AuthorDate: Thu Aug 1 08:19:41 2019 +0000 Commit: Matthias Seidel <msei...@apache.org> CommitDate: Thu Aug 1 08:19:41 2019 +0000 Add close button for high contrast in side bar diff --git a/sfx2/source/sidebar/Theme.cxx b/sfx2/source/sidebar/Theme.cxx index 75dfa3e91dc9..dd0739a3fdd6 100644 --- a/sfx2/source/sidebar/Theme.cxx +++ b/sfx2/source/sidebar/Theme.cxx @@ -41,8 +41,6 @@ namespace sfx2 { namespace sidebar { ::rtl::Reference<Theme> Theme::mpInstance; - - Theme& Theme::GetCurrentTheme (void) { if ( ! mpInstance.is()) @@ -54,8 +52,6 @@ Theme& Theme::GetCurrentTheme (void) } - - Theme::Theme (void) : ThemeInterfaceBase(m_aMutex), maImages(), @@ -76,15 +72,11 @@ Theme::Theme (void) } - - Theme::~Theme (void) { } - - Image Theme::GetImage (const ThemeItem eItem) { const PropertyType eType (GetPropertyType(eItem)); @@ -95,8 +87,6 @@ Image Theme::GetImage (const ThemeItem eItem) } - - Color Theme::GetColor (const ThemeItem eItem) { const PropertyType eType (GetPropertyType(eItem)); @@ -112,8 +102,6 @@ Color Theme::GetColor (const ThemeItem eItem) } - - const Paint& Theme::GetPaint (const ThemeItem eItem) { const PropertyType eType (GetPropertyType(eItem)); @@ -124,16 +112,12 @@ const Paint& Theme::GetPaint (const ThemeItem eItem) } - - const Wallpaper Theme::GetWallpaper (const ThemeItem eItem) { return GetPaint(eItem).GetWallpaper(); } - - sal_Int32 Theme::GetInteger (const ThemeItem eItem) { const PropertyType eType (GetPropertyType(eItem)); @@ -144,8 +128,6 @@ sal_Int32 Theme::GetInteger (const ThemeItem eItem) } - - bool Theme::GetBoolean (const ThemeItem eItem) { const PropertyType eType (GetPropertyType(eItem)); @@ -156,8 +138,6 @@ bool Theme::GetBoolean (const ThemeItem eItem) } - - Rectangle Theme::GetRectangle (const ThemeItem eItem) { const PropertyType eType (GetPropertyType(eItem)); @@ -168,8 +148,6 @@ Rectangle Theme::GetRectangle (const ThemeItem eItem) } - - bool Theme::IsHighContrastMode (void) { const Theme& rTheme (GetCurrentTheme()); @@ -177,8 +155,6 @@ bool Theme::IsHighContrastMode (void) } - - void Theme::HandleDataChange (void) { Theme& rTheme (GetCurrentTheme()); @@ -194,8 +170,6 @@ void Theme::HandleDataChange (void) } - - void Theme::InitializeTheme (void) { setPropertyValue( @@ -207,8 +181,6 @@ void Theme::InitializeTheme (void) } - - void Theme::UpdateTheme (void) { SidebarResource aLocalResource; @@ -385,7 +357,10 @@ void Theme::UpdateTheme (void) : A2S("private:graphicrepository/sfx2/res/symphony/morebutton.png"))); setPropertyValue( maPropertyIdToNameMap[Image_Closer], - Any(A2S("private:graphicrepository/sfx2/res/closedoc.png"))); + Any( + mbIsHighContrastMode + ? A2S("private:graphicrepository/sfx2/res/closedochc.png") + : A2S("private:graphicrepository/sfx2/res/closedoc.png"))); setPropertyValue( maPropertyIdToNameMap[Image_CloseIndicator], Any( @@ -473,8 +448,6 @@ void Theme::UpdateTheme (void) } - - void SAL_CALL Theme::disposing (void) { ChangeListeners aListeners; @@ -506,16 +479,12 @@ void SAL_CALL Theme::disposing (void) } - - Reference<beans::XPropertySet> Theme::GetPropertySet (void) { return Reference<beans::XPropertySet>(static_cast<XWeak*>(&GetCurrentTheme()), UNO_QUERY); } - - Reference<beans::XPropertySetInfo> SAL_CALL Theme::getPropertySetInfo (void) throw(cssu::RuntimeException) { @@ -523,8 +492,6 @@ Reference<beans::XPropertySetInfo> SAL_CALL Theme::getPropertySetInfo (void) } - - void SAL_CALL Theme::setPropertyValue ( const ::rtl::OUString& rsPropertyName, const cssu::Any& rValue) @@ -570,8 +537,6 @@ void SAL_CALL Theme::setPropertyValue ( } - - Any SAL_CALL Theme::getPropertyValue ( const ::rtl::OUString& rsPropertyName) throw(css::beans::UnknownPropertyException, @@ -592,8 +557,6 @@ Any SAL_CALL Theme::getPropertyValue ( } - - void SAL_CALL Theme::addPropertyChangeListener( const ::rtl::OUString& rsPropertyName, const cssu::Reference<css::beans::XPropertyChangeListener>& rxListener) @@ -620,8 +583,6 @@ void SAL_CALL Theme::addPropertyChangeListener( } - - void SAL_CALL Theme::removePropertyChangeListener( const ::rtl::OUString& rsPropertyName, const cssu::Reference<css::beans::XPropertyChangeListener>& rxListener) @@ -658,8 +619,6 @@ void SAL_CALL Theme::removePropertyChangeListener( } - - void SAL_CALL Theme::addVetoableChangeListener( const ::rtl::OUString& rsPropertyName, const cssu::Reference<css::beans::XVetoableChangeListener>& rxListener) @@ -686,8 +645,6 @@ void SAL_CALL Theme::addVetoableChangeListener( } - - void SAL_CALL Theme::removeVetoableChangeListener( const ::rtl::OUString& rsPropertyName, const cssu::Reference<css::beans::XVetoableChangeListener>& rxListener) @@ -723,8 +680,6 @@ void SAL_CALL Theme::removeVetoableChangeListener( } - - cssu::Sequence<css::beans::Property> SAL_CALL Theme::getProperties (void) throw(cssu::RuntimeException) { @@ -751,8 +706,6 @@ cssu::Sequence<css::beans::Property> SAL_CALL Theme::getProperties (void) } - - beans::Property SAL_CALL Theme::getPropertyByName (const ::rtl::OUString& rsPropertyName) throw(css::beans::UnknownPropertyException, cssu::RuntimeException) @@ -775,8 +728,6 @@ beans::Property SAL_CALL Theme::getPropertyByName (const ::rtl::OUString& rsProp } - - sal_Bool SAL_CALL Theme::hasPropertyByName (const ::rtl::OUString& rsPropertyName) throw(cssu::RuntimeException) { @@ -792,8 +743,6 @@ sal_Bool SAL_CALL Theme::hasPropertyByName (const ::rtl::OUString& rsPropertyNam } - - void Theme::SetupPropertyMaps (void) { maPropertyIdToNameMap.resize(__Post_Rect); @@ -870,8 +819,6 @@ void Theme::SetupPropertyMaps (void) } - - Theme::PropertyType Theme::GetPropertyType (const ThemeItem eItem) { switch(eItem) @@ -946,8 +893,6 @@ Theme::PropertyType Theme::GetPropertyType (const ThemeItem eItem) } - - cssu::Type Theme::GetCppuType (const PropertyType eType) { switch(eType) @@ -977,8 +922,6 @@ cssu::Type Theme::GetCppuType (const PropertyType eType) } - - sal_Int32 Theme::GetIndex (const ThemeItem eItem, const PropertyType eType) { switch(eType) @@ -1003,8 +946,6 @@ sal_Int32 Theme::GetIndex (const ThemeItem eItem, const PropertyType eType) } - - Theme::VetoableListenerContainer* Theme::GetVetoableListeners ( const ThemeItem eItem, const bool bCreate) @@ -1022,8 +963,6 @@ Theme::VetoableListenerContainer* Theme::GetVetoableListeners ( } - - Theme::ChangeListenerContainer* Theme::GetChangeListeners ( const ThemeItem eItem, const bool bCreate) @@ -1041,8 +980,6 @@ Theme::ChangeListenerContainer* Theme::GetChangeListeners ( } - - bool Theme::DoVetoableListenersVeto ( const VetoableListenerContainer* pListeners, const beans::PropertyChangeEvent& rEvent) const @@ -1074,8 +1011,6 @@ bool Theme::DoVetoableListenersVeto ( } - - void Theme::BroadcastPropertyChange ( const ChangeListenerContainer* pListeners, const beans::PropertyChangeEvent& rEvent) const @@ -1102,8 +1037,6 @@ void Theme::BroadcastPropertyChange ( } - - void Theme::ProcessNewValue ( const Any& rValue, const ThemeItem eItem, @@ -1182,7 +1115,4 @@ void Theme::ProcessNewValue ( } } - - - } } // end of namespace sfx2::sidebar _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits