nux-1.16.0
nux::TabView Class Reference
Inheritance diagram for nux::TabView:
nux::View nux::InputArea nux::Area nux::InitiallyUnownedObject nux::Focusable nux::Object nux::Trackable nux::Introspectable

List of all members.

Classes

class  TabElement

Public Member Functions

 TabView (NUX_FILE_LINE_PROTO)
virtual AreaFindAreaUnderMouse (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 ()

Detailed Description

Definition at line 34 of file TabView.h.


Member Function Documentation

Area * nux::TabView::FindAreaUnderMouse ( const Point mouse_position,
NuxEventType  event_type 
) [virtual]

Return the area under the mouse pointer.

Returns:
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;
  }

The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends