~om26er/ubuntu/oneiric/nux/sru-888039

« back to all changes in this revision

Viewing changes to Nux/BaseWindow.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Didier Roche
  • Date: 2011-07-21 18:41:46 UTC
  • mfrom: (1.1.23 upstream)
  • Revision ID: james.westby@ubuntu.com-20110721184146-po1lz9xhvsz1x7kt
Tags: 1.0.6-0ubuntu1
* New upstream release.
* debian/control:
  - dep on libglu1-mesa-dev
* debian/rules:
  - bump shlib

Show diffs side-by-side

added added

removed removed

Lines of Context:
66
66
    _entering_visible_state = false;
67
67
    _entering_hidden_state = false;
68
68
    _enter_focus_input_area = NULL;
 
69
    accept_key_nav_focus_ = false;
69
70
 
70
71
    // Should be at the end of the constructor
71
72
    GetWindowCompositor().RegisterWindow (this);
124
125
    return ret;
125
126
  }
126
127
 
 
128
  Area* BaseWindow::FindAreaUnderMouse(const Point& mouse_position, NuxEventType event_type)
 
129
  {
 
130
    bool mouse_inside = TestMousePointerInclusionFilterMouseWheel(mouse_position, event_type);
 
131
 
 
132
    if(mouse_inside == false)
 
133
      return NULL;
 
134
 
 
135
    if(m_layout)
 
136
    {
 
137
      nuxAssert(m_layout->IsLayout());
 
138
      Area* found_area = m_layout->FindAreaUnderMouse(mouse_position, event_type);
 
139
      if(found_area)
 
140
        return found_area;
 
141
    }
 
142
 
 
143
    if((event_type == NUX_MOUSE_WHEEL) && (!AcceptMouseWheelEvent()))
 
144
      return NULL;
 
145
    return this;
 
146
  }
 
147
 
127
148
  void BaseWindow::Draw (GraphicsEngine &GfxContext, bool force_draw)
128
149
  {
129
150
    Geometry base = GetGeometry();
538
559
  {
539
560
    return _opacity;
540
561
  }
 
562
 
 
563
  void BaseWindow::SetAcceptKeyNavFocus(bool accept)
 
564
  {
 
565
    accept_key_nav_focus_ = accept;
 
566
  }
 
567
 
 
568
  bool BaseWindow::AcceptKeyNavFocus()
 
569
  {
 
570
    return accept_key_nav_focus_;
 
571
  }
541
572
}
542
573