From 056a997e3934c58e183407349d4d45619822c89a Mon Sep 17 00:00:00 2001 From: fluxgen Date: Fri, 12 Sep 2003 23:38:50 +0000 Subject: fixed new theme items --- src/FbWinFrame.cc | 45 +++++++++++++++++++++++++-------------------- src/FbWinFrame.hh | 4 ++-- 2 files changed, 27 insertions(+), 22 deletions(-) diff --git a/src/FbWinFrame.cc b/src/FbWinFrame.cc index 387b159..81ba7de 100644 --- a/src/FbWinFrame.cc +++ b/src/FbWinFrame.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: FbWinFrame.cc,v 1.49 2003/09/12 22:49:14 fluxgen Exp $ +// $Id: FbWinFrame.cc,v 1.50 2003/09/12 23:38:50 fluxgen Exp $ #include "FbWinFrame.hh" @@ -238,10 +238,6 @@ void FbWinFrame::setDoubleClickTime(unsigned int time) { m_double_click_time = time; } -void FbWinFrame::setBevel(int bevel) { - m_bevel = bevel; -} - void FbWinFrame::addLeftButton(FbTk::Button *btn) { if (btn == 0) // valid button? return; @@ -596,6 +592,15 @@ void FbWinFrame::reconfigure() { if (m_labelbuttons.size() == 0) return; + m_bevel = theme().bevelWidth(); + + handle().resize(handle().width(), + theme().handleWidth()); + gripLeft().resize(buttonHeight(), + theme().handleWidth()); + gripRight().resize(gripLeft().width(), + gripLeft().height()); + // align titlebar and render it if (m_use_titlebar) reconfigureTitlebar(); @@ -1107,21 +1112,21 @@ void FbWinFrame::renderButtonUnfocus(FbTk::TextButton &button) { void FbWinFrame::updateTransparent() { redrawTitlebar(); - /* - ButtonList::iterator button_it = m_buttons_left.begin(); - ButtonList::iterator button_it_end = m_buttons_left.begin(); - for (; button_it != button_it_end; ++button_it) { - (*button_it)->clear(); - (*button_it)->updateTransparent(); - } - - button_it = m_buttons_right.begin(); - button_it_end = m_buttons_right.end(); - for (; button_it != button_it_end; ++button_it) { - (*button_it)->clear(); - (*button_it)->updateTransparent(); - } - */ + + ButtonList::iterator button_it = m_buttons_left.begin(); + ButtonList::iterator button_it_end = m_buttons_left.begin(); + for (; button_it != button_it_end; ++button_it) { + (*button_it)->clear(); + (*button_it)->updateTransparent(); + } + + button_it = m_buttons_right.begin(); + button_it_end = m_buttons_right.end(); + for (; button_it != button_it_end; ++button_it) { + (*button_it)->clear(); + (*button_it)->updateTransparent(); + } + m_grip_left.updateTransparent(); m_grip_right.updateTransparent(); m_handle.updateTransparent(); diff --git a/src/FbWinFrame.hh b/src/FbWinFrame.hh index 3040b68..70ecaf0 100644 --- a/src/FbWinFrame.hh +++ b/src/FbWinFrame.hh @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: FbWinFrame.hh,v 1.18 2003/09/12 22:49:14 fluxgen Exp $ +// $Id: FbWinFrame.hh,v 1.19 2003/09/12 23:38:50 fluxgen Exp $ #ifndef FBWINFRAME_HH #define FBWINFRAME_HH @@ -86,7 +86,7 @@ public: /// set focus/unfocus style void setFocus(bool newvalue); void setDoubleClickTime(unsigned int time); - void setBevel(int bevel); + /// add a button to the left of the label void addLeftButton(FbTk::Button *btn); /// add a button to the right of the label -- cgit v0.11.2