Menu Class Reference

#include <menu.h>

Inherits Widget.

Inheritance diagram for Menu:

Inheritance graph
[legend]
Collaboration diagram for Menu:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 Menu (Monitor *monitor)
 Menu class implementation.
 ~Menu ()
void manage ()
void updateItemTree ()
void illuminate ()
void handleButtonPress (XButtonEvent *event)
void handleMotionNotify (XMotionEvent *event)
virtual void show ()
virtual void hide ()

Private Member Functions

void initActions ()
void escape ()

Private Attributes

Themetheme_
Labellabel_
LAction actions_
Itemroot_
ItemsubRoot_
Itemselected_

Detailed Description

Basic menu for action, cut'n'paste and re-attach stuff.

Definition at line 79 of file menu.h.


Constructor & Destructor Documentation

Menu::Menu ( Monitor monitor  ) 

Menu class implementation.

Definition at line 119 of file menu.cpp.

References Widget::gc(), initActions(), label_, Label::LEFT, Widget::monitor(), root_, selected_, Rectangle::setHeight(), Rectangle::setWidth(), Rectangle::setX(), Rectangle::setY(), subRoot_, Monitor::theme(), theme_, and Widget::window().

Here is the call graph for this function:

Menu::~Menu (  ) 

Definition at line 134 of file menu.cpp.


Member Function Documentation

void Menu::manage (  ) 

Definition at line 272 of file menu.cpp.

References Rectangle::height(), illuminate(), Widget::isVisible(), Item::items(), label_, Widget::monitor(), Widget::resize(), Rectangle::setHeight(), Label::setText(), Rectangle::setWidth(), Rectangle::setY(), subRoot_, Label::textWidth(), and Rectangle::y().

Referenced by handleButtonPress(), and show().

Here is the call graph for this function:

void Menu::updateItemTree (  ) 

Definition at line 165 of file menu.cpp.

References Item::ACTION, actions_, Item::addItem(), Container< P, LT, LTI, T >::begin(), Item::CLIENT, Item::DCLIENT, Monitor::detachedClients(), Container< P, LT, LTI, T >::end(), Item::items(), Widget::monitor(), Item::ROOT, root_, Item::SEPARATOR, Container< P, LT, LTI, T >::size(), Client::STICKY, Monitor::stickyClients(), subRoot_, and Item::WORKSPACE.

Referenced by handleButtonPress(), and show().

Here is the call graph for this function:

void Menu::illuminate (  ) 

called on Expose by Kernel.

Definition at line 234 of file menu.cpp.

References Theme::BAR_BACKGROUND, Theme::BAR_SHADOW, Theme::BAR_SHINE, Draw::drawRectBorder(), Widget::gc(), Rectangle::height(), Item::items(), label_, Theme::LABEL_BACKGROUND_FOCUSSED, Theme::LABEL_BACKGROUND_NORMAL, Theme::LABEL_SHADOW_FOCUSSED, Theme::LABEL_SHADOW_NORMAL, Theme::LABEL_SHINE_FOCUSSED, Theme::LABEL_SHINE_NORMAL, Theme::LABEL_TEXT_FOCUSSED, Theme::LABEL_TEXT_NORMAL, LOGDEBUG, selected_, Item::SEPARATOR, Label::setText(), Rectangle::setX(), Rectangle::setY(), subRoot_, theme_, Label::update(), Widget::window(), and XCORE.

Referenced by handleMotionNotify(), and manage().

Here is the call graph for this function:

void Menu::handleButtonPress ( XButtonEvent *  event  ) 

Definition at line 303 of file menu.cpp.

References Item::ACTION, Monitor::attachDetachedClient(), Monitor::attachLastClient(), Item::CLIENT, Client::clientWindow(), Item::data(), Item::DCLIENT, Monitor::detachClient(), escape(), Workspace::focus(), Monitor::focus(), Rectangle::height(), Action::isValid(), Item::items(), manage(), Widget::monitor(), Item::parent(), Action::perform(), Item::ROOTITEM, selected_, subRoot_, Item::type(), updateItemTree(), Rectangle::width(), Widget::window(), Item::WORKSPACE, Rectangle::x(), XCORE, and Rectangle::y().

Referenced by Kernel::handleButtonPress().

Here is the call graph for this function:

void Menu::handleMotionNotify ( XMotionEvent *  event  ) 

Definition at line 385 of file menu.cpp.

References Rectangle::height(), illuminate(), Item::items(), label_, LOGDEBUG, selected_, and subRoot_.

Referenced by Kernel::handleMotionNotify().

Here is the call graph for this function:

void Menu::show (  )  [virtual]

Reimplemented from Widget.

Definition at line 220 of file menu.cpp.

References Widget::isVisible_, KERNEL, manage(), updateItemTree(), Widget::window(), and XCORE.

Referenced by ClientBar::toggleMenuMode().

Here is the call graph for this function:

void Menu::hide (  )  [virtual]

Reimplemented from Widget.

Definition at line 228 of file menu.cpp.

References Widget::isVisible_, KERNEL, Widget::window(), and XCORE.

Referenced by ClientBar::toggleMenuMode().

Here is the call graph for this function:

void Menu::initActions (  )  [private]

Definition at line 138 of file menu.cpp.

References actions_, Util::get(), KERNEL, and LOGWARN.

Referenced by Menu().

Here is the call graph for this function:

void Menu::escape (  )  [private]

Definition at line 381 of file menu.cpp.

References Monitor::clientBar(), Widget::monitor(), and ClientBar::toggleMenuMode().

Referenced by handleButtonPress().

Here is the call graph for this function:


Member Data Documentation

Theme* Menu::theme_ [private]

Definition at line 105 of file menu.h.

Referenced by illuminate(), and Menu().

Label* Menu::label_ [private]

Definition at line 106 of file menu.h.

Referenced by handleMotionNotify(), illuminate(), manage(), and Menu().

LAction Menu::actions_ [private]

Definition at line 107 of file menu.h.

Referenced by initActions(), and updateItemTree().

Item* Menu::root_ [private]

Definition at line 108 of file menu.h.

Referenced by Menu(), and updateItemTree().

Item* Menu::subRoot_ [private]

Definition at line 109 of file menu.h.

Referenced by handleButtonPress(), handleMotionNotify(), illuminate(), manage(), Menu(), and updateItemTree().

Item* Menu::selected_ [private]

Definition at line 110 of file menu.h.

Referenced by handleButtonPress(), handleMotionNotify(), illuminate(), and Menu().


The documentation for this class was generated from the following files:
Generated on Thu May 24 15:20:19 2007 for ncwm by  doxygen 1.5.1