Index: ui/views/view.h |
diff --git a/ui/views/view.h b/ui/views/view.h |
index 2d028ef289e32b96e6c48006160f5199f2ad9af8..78558c9b82a67fcd0af60b4f35ab5c9127d8aac5 100644 |
--- a/ui/views/view.h |
+++ b/ui/views/view.h |
@@ -25,6 +25,7 @@ |
#include "ui/gfx/rect.h" |
#include "ui/views/background.h" |
#include "ui/views/border.h" |
+#include "ui/views/focus_border.h" |
#if defined(OS_WIN) |
#include "base/win/scoped_comptr.h" |
@@ -59,6 +60,7 @@ class Background; |
class Border; |
class ContextMenuController; |
class DragController; |
+class FocusBorder; |
class FocusManager; |
class FocusTraversable; |
class InputMethod; |
@@ -458,6 +460,11 @@ class VIEWS_EXPORT View : public ui::LayerDelegate, |
const Border* border() const { return border_.get(); } |
Border* border() { return border_.get(); } |
+ // The focus_border object is owned by this object and may be NULL. |
+ void set_focus_border(FocusBorder* b) { focus_border_.reset(b); } |
+ const FocusBorder* focus_border() const { return focus_border_.get(); } |
+ FocusBorder* focus_border() { return focus_border_.get(); } |
+ |
// Get the theme provider from the parent widget. |
virtual ui::ThemeProvider* GetThemeProvider() const; |
@@ -983,8 +990,8 @@ class VIEWS_EXPORT View : public ui::LayerDelegate, |
// Override to paint a border not specified by SetBorder(). |
virtual void OnPaintBorder(gfx::Canvas* canvas); |
- // Override to paint a focus border (usually a dotted rectangle) around |
- // relevant contents. |
+ // Override to paint a focus border not specified by set_focus_border() around |
+ // relevant contents. The focus border is usually a dotted rectangle. |
virtual void OnPaintFocusBorder(gfx::Canvas* canvas); |
// Accelerated painting ------------------------------------------------------ |
@@ -1415,6 +1422,9 @@ class VIEWS_EXPORT View : public ui::LayerDelegate, |
// Border. |
scoped_ptr<Border> border_; |
+ // Focus border. |
+ scoped_ptr<FocusBorder> focus_border_; |
+ |
// RTL painting -------------------------------------------------------------- |
// Indicates whether or not the gfx::Canvas object passed to View::Paint() |