| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef UI_VIEWS_COCOA_BRIDGED_CONTENT_VIEW_H_ | 5 #ifndef UI_VIEWS_COCOA_BRIDGED_CONTENT_VIEW_H_ |
| 6 #define UI_VIEWS_COCOA_BRIDGED_CONTENT_VIEW_H_ | 6 #define UI_VIEWS_COCOA_BRIDGED_CONTENT_VIEW_H_ |
| 7 | 7 |
| 8 #import <Cocoa/Cocoa.h> | 8 #import <Cocoa/Cocoa.h> |
| 9 | 9 |
| 10 #import "ui/base/cocoa/tracking_area.h" | 10 #import "ui/base/cocoa/tracking_area.h" |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 @private | 25 @private |
| 26 // Weak. The hosted RootView, owned by hostedView_->GetWidget(). | 26 // Weak. The hosted RootView, owned by hostedView_->GetWidget(). |
| 27 views::View* hostedView_; | 27 views::View* hostedView_; |
| 28 | 28 |
| 29 // Weak. If non-null the TextInputClient of the currently focused View in the | 29 // Weak. If non-null the TextInputClient of the currently focused View in the |
| 30 // hierarchy rooted at |hostedView_|. Owned by the focused View. | 30 // hierarchy rooted at |hostedView_|. Owned by the focused View. |
| 31 ui::TextInputClient* textInputClient_; | 31 ui::TextInputClient* textInputClient_; |
| 32 | 32 |
| 33 // A tracking area installed to enable mouseMoved events. | 33 // A tracking area installed to enable mouseMoved events. |
| 34 ui::ScopedCrTrackingArea trackingArea_; | 34 ui::ScopedCrTrackingArea trackingArea_; |
| 35 |
| 36 // Whether the view is reacting to a keyDown event on the view. |
| 37 BOOL inKeyDown_; |
| 35 } | 38 } |
| 36 | 39 |
| 37 @property(readonly, nonatomic) views::View* hostedView; | 40 @property(readonly, nonatomic) views::View* hostedView; |
| 38 @property(assign, nonatomic) ui::TextInputClient* textInputClient; | 41 @property(assign, nonatomic) ui::TextInputClient* textInputClient; |
| 39 | 42 |
| 40 // Initialize the NSView -> views::View bridge. |viewToHost| must be non-NULL. | 43 // Initialize the NSView -> views::View bridge. |viewToHost| must be non-NULL. |
| 41 - (id)initWithView:(views::View*)viewToHost; | 44 - (id)initWithView:(views::View*)viewToHost; |
| 42 | 45 |
| 43 // Clear the hosted view. For example, if it is about to be destroyed. | 46 // Clear the hosted view. For example, if it is about to be destroyed. |
| 44 - (void)clearView; | 47 - (void)clearView; |
| 45 | 48 |
| 46 // Process a mouse event captured while the widget had global mouse capture. | 49 // Process a mouse event captured while the widget had global mouse capture. |
| 47 - (void)processCapturedMouseEvent:(NSEvent*)theEvent; | 50 - (void)processCapturedMouseEvent:(NSEvent*)theEvent; |
| 48 | 51 |
| 49 @end | 52 @end |
| 50 | 53 |
| 51 #endif // UI_VIEWS_COCOA_BRIDGED_CONTENT_VIEW_H_ | 54 #endif // UI_VIEWS_COCOA_BRIDGED_CONTENT_VIEW_H_ |
| OLD | NEW |