nux-1.14.0
|
Classes | |
class | TabElement |
Public Member Functions | |
TabView (NUX_FILE_LINE_PROTO) | |
virtual Area * | FindAreaUnderMouse (const Point &mouse_position, NuxEventType event_type) |
virtual long | ProcessEvent (IEvent &ievent, long TraverseInfo, long ProcessEventInfo) |
virtual void | Draw (GraphicsEngine &GfxContext, bool force_draw) |
virtual void | DrawContent (GraphicsEngine &GfxContext, bool force_draw) |
virtual void | PostDraw (GraphicsEngine &GfxContext, bool force_draw) |
void | AddTab (const char *tab_name, Layout *tab_layout) |
void | SetActiveTad (int index) |
virtual bool | CanBreakLayout () |
Return true if this object can break the layout. | |
void | RecvTabMouseDown (int x, int y, unsigned long button_flags, unsigned long key_flags, TabElement *) |
void | RecvTabMouseUp (int x, int y, unsigned long button_flags, unsigned long key_flags, TabElement *) |
void | RecvMouseEnter (int x, int y, unsigned long button_flags, unsigned long key_flags) |
void | RecvMouseLeave (int x, int y, unsigned long button_flags, unsigned long key_flags) |
Public Attributes | |
sigc::signal< void, TabView * > | sigTabChanged |
sigc::signal< void, int > | sigTabIndexChanged |
Protected Member Functions | |
virtual bool | AcceptKeyNavFocus () |
Area * nux::TabView::FindAreaUnderMouse | ( | const Point & | mouse_position, |
NuxEventType | event_type | ||
) | [virtual] |
Return the area under the mouse pointer.
Reimplemented from nux::View.
Definition at line 177 of file TabView.cpp.
References nux::Layout::FindAreaUnderMouse(), nux::Area::TestMousePointerInclusion(), and nux::Area::TestMousePointerInclusionFilterMouseWheel().
{ bool mouse_inside = TestMousePointerInclusionFilterMouseWheel(mouse_position, event_type); if(mouse_inside == false) return NULL; NUX_RETURN_VALUE_IF_TRUE(_scroll_right->TestMousePointerInclusion(mouse_position, event_type), _scroll_right); NUX_RETURN_VALUE_IF_TRUE(_scroll_left->TestMousePointerInclusion(mouse_position, event_type), _scroll_left); t_u32 vector_size = (t_u32) _tab_array.size(); for(t_u32 i = 0; i < vector_size; i++) { NUX_RETURN_VALUE_IF_TRUE(_tab_array[i]->_tab_area->TestMousePointerInclusion(mouse_position, event_type), _tab_array[i]->_tab_area); } if(_visible_tab_content_layout) { nuxAssert(_visible_tab_content_layout->IsLayout()); Area* found_area = _visible_tab_content_layout->FindAreaUnderMouse(mouse_position, event_type); if(found_area) return found_area; } return this; }