author | sandman <sandman> | 2002-06-30 20:34:40 (UTC) |
---|---|---|
committer | sandman <sandman> | 2002-06-30 20:34:40 (UTC) |
commit | 8d8081142f19cf697c4a1fe044add4e2db9a36b2 (patch) (side-by-side diff) | |
tree | 200b2c26f47cb8b66652414dbc0fa5f96686cc6a /noncore/styles/liquid/liquid.cpp | |
parent | 1c6b25945236e3d6e4dd611ec6fc6003d5f87280 (diff) | |
download | opie-8d8081142f19cf697c4a1fe044add4e2db9a36b2.zip opie-8d8081142f19cf697c4a1fe044add4e2db9a36b2.tar.gz opie-8d8081142f19cf697c4a1fe044add4e2db9a36b2.tar.bz2 |
ew feature - when liquid is active a new window decoration is set
(this deco is inspired by the classic KDE liquid kwin style)
Diffstat (limited to 'noncore/styles/liquid/liquid.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/styles/liquid/liquid.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/noncore/styles/liquid/liquid.cpp b/noncore/styles/liquid/liquid.cpp index 2b6eaa4..9a7d2dd 100644 --- a/noncore/styles/liquid/liquid.cpp +++ b/noncore/styles/liquid/liquid.cpp @@ -1,24 +1,25 @@ /*- * Copyright (C)QPL 2001 Daniel M. Duley. All rights reserved. */ #ifndef INCLUDE_MENUITEM_DEF #define INCLUDE_MENUITEM_DEF #endif #include <qmenudata.h> #include "liquid.h" +#include "liquiddeco.h" #include <qapplication.h> #include <qpe/config.h> #include "effects.h" #include <qpalette.h> #include <qbitmap.h> #include <qtabbar.h> #include <qpopupmenu.h> #include <qobjectlist.h> #include <qimage.h> #include <qtimer.h> #include <qpixmapcache.h> #include <qradiobutton.h> @@ -978,33 +979,37 @@ void LiquidStyle::unPolish(QWidget *w) void LiquidStyle::polish(QApplication *app) { QWindowsStyle::polish(app); menuAni = app->isEffectEnabled(UI_AnimateMenu); menuFade = app->isEffectEnabled(UI_FadeMenu); if(menuAni) app->setEffectEnabled(UI_AnimateMenu, false); if(menuFade) app->setEffectEnabled(UI_FadeMenu, false); qt_set_draw_menu_bar_impl((QDrawMenuBarItemImpl) &LiquidStyle::drawMenuBarItem); + + QApplication::qwsSetDecoration ( new LiquidDecoration ( )); } void LiquidStyle::unPolish(QApplication *app) { QWindowsStyle::unPolish(app); app->setEffectEnabled(UI_AnimateMenu, menuAni); app->setEffectEnabled(UI_FadeMenu, menuFade); qt_set_draw_menu_bar_impl ( 0 ); + + QApplication::qwsSetDecoration ( new QPEDecoration ( )); } /* * This is a fun method ;-) Here's an overview. KToolBar grabs resize to * force everything to erase and repaint on resize. This is going away, I'm * trying to get shaped widgets to work right without masking. QPushButton, * QComboBox, and Panel applet handles capture mouse enter and leaves in order * to set the highlightwidget and repaint for mouse hovers. CheckBoxes and * RadioButtons need to do this differently. Qt buffers these in pixmaps and * caches them in QPixmapCache, which is bad for doing things like hover * because the style methods aren't called in paintEvents if everything * is cached. We use our own Paint event handler instead. Taskbuttons and |