aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dw/ruler.cc12
-rw-r--r--dw/ruler.hh2
2 files changed, 14 insertions, 0 deletions
diff --git a/dw/ruler.cc b/dw/ruler.cc
index bff43479..fc0bbce6 100644
--- a/dw/ruler.cc
+++ b/dw/ruler.cc
@@ -79,6 +79,18 @@ void Ruler::draw (core::View *view, core::Rectangle *area,
drawWidgetBox (view, area, false);
}
+core::Widget *Ruler::getWidgetAtPoint (int x, int y,
+ core::GettingWidgetAtPointContext
+ *context)
+{
+ // Override (complex) implementation OOFAwareWidget::getWidgetAtPoint().
+
+ if (inAllocation (x, y))
+ return this;
+ else
+ return NULL;
+}
+
core::Iterator *Ruler::iterator (core::Content::Type mask, bool atEnd)
{
/** \todo TextIterator? */
diff --git a/dw/ruler.hh b/dw/ruler.hh
index 74323d95..a3c6c962 100644
--- a/dw/ruler.hh
+++ b/dw/ruler.hh
@@ -26,6 +26,8 @@ protected:
bool usesAvailWidth ();
void draw (core::View *view, core::Rectangle *area,
core::DrawingContext *context);
+ core::Widget *getWidgetAtPoint (int x, int y,
+ core::GettingWidgetAtPointContext *context);
public:
static int CLASS_ID;