Index: chrome/browser/renderer_host/render_widget_host_view_mac.h |
diff --git a/chrome/browser/renderer_host/render_widget_host_view_mac.h b/chrome/browser/renderer_host/render_widget_host_view_mac.h |
index 0ddfbbab5b4c39f518c095960a1c6087334ead98..7b18f5cf4d1653d7b7c84f60948860627a409b77 100644 |
--- a/chrome/browser/renderer_host/render_widget_host_view_mac.h |
+++ b/chrome/browser/renderer_host/render_widget_host_view_mac.h |
@@ -120,8 +120,11 @@ class RWHVMEditCommandHelper; |
// etc. |
EditCommands editCommands_; |
- // The plugin for which IME is currently enabled (-1 if not enabled). |
- int pluginImeIdentifier_; |
+ // The plugin that currently has focus (-1 if no plugin has focus). |
+ int focusedPluginIdentifier_; |
+ |
+ // Whether or not plugin IME is currently enabled active. |
+ BOOL pluginImeActive_; |
} |
@property(assign, nonatomic) NSRect caretRect; |
@@ -141,8 +144,10 @@ class RWHVMEditCommandHelper; |
- (void)cancelComposition; |
// Confirm ongoing composition. |
- (void)confirmComposition; |
-// Enables or disables plugin IME for the given plugin. |
-- (void)setPluginImeEnabled:(BOOL)enabled forPlugin:(int)pluginId; |
+// Enables or disables plugin IME. |
+- (void)setPluginImeActive:(BOOL)active; |
+// Updates the current plugin focus state. |
+- (void)pluginFocusChanged:(BOOL)focused forPlugin:(int)pluginId; |
// Evaluates the event in the context of plugin IME, if plugin IME is enabled. |
// Returns YES if the event was handled. |
- (BOOL)postProcessEventForPluginIme:(NSEvent*)event; |
@@ -219,7 +224,8 @@ class RenderWidgetHostViewMac : public RenderWidgetHostView { |
virtual void OnAccessibilityNotifications( |
const std::vector<ViewHostMsg_AccessibilityNotification_Params>& params); |
- virtual void SetPluginImeEnabled(bool enabled, int plugin_id); |
+ virtual void PluginFocusChanged(bool focused, int plugin_id); |
+ virtual void StartPluginIme(); |
virtual bool PostProcessEventForPluginIme( |
const NativeWebKeyboardEvent& event); |
@@ -269,8 +275,8 @@ class RenderWidgetHostViewMac : public RenderWidgetHostView { |
void SetTextInputActive(bool active); |
- // Sends confirmed plugin IME text back to the renderer. |
- void PluginImeCompositionConfirmed(const string16& text, int plugin_id); |
+ // Sends completed plugin IME notification and text back to the renderer. |
+ void PluginImeCompositionCompleted(const string16& text, int plugin_id); |
const std::string& selected_text() const { return selected_text_; } |