OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_MAC_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_MAC_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_MAC_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_MAC_H_ |
7 | 7 |
8 #import <Cocoa/Cocoa.h> | 8 #import <Cocoa/Cocoa.h> |
9 #include <IOSurface/IOSurfaceAPI.h> | 9 #include <IOSurface/IOSurfaceAPI.h> |
10 #include <list> | 10 #include <list> |
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
575 | 575 |
576 // Called when a GPU SwapBuffers is received. | 576 // Called when a GPU SwapBuffers is received. |
577 void GotAcceleratedFrame(); | 577 void GotAcceleratedFrame(); |
578 | 578 |
579 // Called when a software DIB is received. | 579 // Called when a software DIB is received. |
580 void GotSoftwareFrame(); | 580 void GotSoftwareFrame(); |
581 | 581 |
582 // IPC message handlers. | 582 // IPC message handlers. |
583 void OnPluginFocusChanged(bool focused, int plugin_id); | 583 void OnPluginFocusChanged(bool focused, int plugin_id); |
584 void OnStartPluginIme(); | 584 void OnStartPluginIme(); |
| 585 void OnGetRenderedTextCompleted(const std::string& text); |
585 | 586 |
586 // Convert |rect| from the views coordinate (upper-left origin) into | 587 // Convert |rect| from the views coordinate (upper-left origin) into |
587 // the OpenGL coordinate (lower-left origin) and scale for HiDPI displays. | 588 // the OpenGL coordinate (lower-left origin) and scale for HiDPI displays. |
588 gfx::Rect GetScaledOpenGLPixelRect(const gfx::Rect& rect); | 589 gfx::Rect GetScaledOpenGLPixelRect(const gfx::Rect& rect); |
589 | 590 |
590 // Send updated vsync parameters to the renderer. | 591 // Send updated vsync parameters to the renderer. |
591 void SendVSyncParametersToRenderer(); | 592 void SendVSyncParametersToRenderer(); |
592 | 593 |
| 594 // Dispatches a TTS session. |
| 595 void SpeakText(const std::string& text); |
| 596 |
593 // The associated view. This is weak and is inserted into the view hierarchy | 597 // The associated view. This is weak and is inserted into the view hierarchy |
594 // to own this RenderWidgetHostViewMac object. Set to nil at the start of the | 598 // to own this RenderWidgetHostViewMac object. Set to nil at the start of the |
595 // destructor. | 599 // destructor. |
596 RenderWidgetHostViewCocoa* cocoa_view_; | 600 RenderWidgetHostViewCocoa* cocoa_view_; |
597 | 601 |
598 // Indicates if the page is loading. | 602 // Indicates if the page is loading. |
599 bool is_loading_; | 603 bool is_loading_; |
600 | 604 |
601 // Whether it's allowed to pause waiting for a new frame. | 605 // Whether it's allowed to pause waiting for a new frame. |
602 bool allow_pause_for_resize_or_repaint_; | 606 bool allow_pause_for_resize_or_repaint_; |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
638 scoped_ptr<RenderWidgetHostViewFrameSubscriber> frame_subscriber_; | 642 scoped_ptr<RenderWidgetHostViewFrameSubscriber> frame_subscriber_; |
639 | 643 |
640 base::WeakPtrFactory<RenderWidgetHostViewMac> | 644 base::WeakPtrFactory<RenderWidgetHostViewMac> |
641 software_frame_weak_ptr_factory_; | 645 software_frame_weak_ptr_factory_; |
642 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewMac); | 646 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewMac); |
643 }; | 647 }; |
644 | 648 |
645 } // namespace content | 649 } // namespace content |
646 | 650 |
647 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_MAC_H_ | 651 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_MAC_H_ |
OLD | NEW |