From 8f0b2b2016d0023f928bab973936cf049fe9a30a Mon Sep 17 00:00:00 2001 From: fluxgen Date: Fri, 29 Aug 2003 00:48:41 +0000 Subject: minor fixes --- src/IconbarTheme.cc | 5 +++-- src/ToolTheme.cc | 11 +++++++---- src/ToolTheme.hh | 6 +++++- 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/src/IconbarTheme.cc b/src/IconbarTheme.cc index 1c84a78..3c73376 100644 --- a/src/IconbarTheme.cc +++ b/src/IconbarTheme.cc @@ -20,7 +20,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: IconbarTheme.cc,v 1.6 2003/08/28 23:51:26 fluxgen Exp $ +// $Id: IconbarTheme.cc,v 1.7 2003/08/29 00:48:41 fluxgen Exp $ #include "IconbarTheme.hh" #include "FbTk/App.hh" @@ -69,6 +69,7 @@ bool IconbarTheme::fallback(FbTk::ThemeItem_base &item) { tmp_item.load(); // copy texture *m_focused_texture = *tmp_item; + return true; } else if (&m_unfocused_texture == &item) { // special case for textures since they're using .load() FbTk::ThemeItem tmp_item(m_unfocused_texture.theme(), @@ -76,7 +77,7 @@ bool IconbarTheme::fallback(FbTk::ThemeItem_base &item) { tmp_item.load(); // copy texture *m_unfocused_texture = *tmp_item; - + return true; } else if (&m_empty_texture == &item) { return (tm.loadItem(item, m_focused_texture.name(), m_focused_texture.altName()) ? true : diff --git a/src/ToolTheme.cc b/src/ToolTheme.cc index 77c6ea4..730c9a3 100644 --- a/src/ToolTheme.cc +++ b/src/ToolTheme.cc @@ -20,7 +20,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: ToolTheme.cc,v 1.3 2003/08/19 21:27:40 fluxgen Exp $ +// $Id: ToolTheme.cc,v 1.4 2003/08/29 00:46:18 fluxgen Exp $ #include "ToolTheme.hh" @@ -41,9 +41,12 @@ void ToolTheme::reconfigTheme() { update(); } - bool ToolTheme::fallback(FbTk::ThemeItem_base &item) { - if (item.name() == "toolbar.workspace") - return FbTk::ThemeManager::instance().loadItem(item, "toolbar.label", "Toolbar.Label"); + if (item.name().find(".justify") != std::string::npos) { + return FbTk::ThemeManager::instance().loadItem(item, + "toolbar.justify", + "Toolbar.Justify"); + } + return false; } diff --git a/src/ToolTheme.hh b/src/ToolTheme.hh index 3ffe13b..24ae863 100644 --- a/src/ToolTheme.hh +++ b/src/ToolTheme.hh @@ -20,7 +20,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: ToolTheme.hh,v 1.3 2003/08/19 21:27:39 fluxgen Exp $ +// $Id: ToolTheme.hh,v 1.4 2003/08/29 00:45:41 fluxgen Exp $ #ifndef TOOLTHEME_HH #define TOOLTHEME_HH @@ -46,6 +46,10 @@ public: // textures const FbTk::Texture &texture() const { return *m_texture; } const BorderTheme &border() const { return m_border; } + +protected: + FbTk::ThemeItem &textureTheme() { return m_texture; } + private: FbTk::ThemeItem m_texture; BorderTheme m_border; -- cgit v0.11.2