Auto merge of #9201 - wenderen:8512-task-thread, r=jdm

task -> thread

for #8512

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9201)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2016-01-10 15:49:04 +05:30
commit d3e2f94f20
119 changed files with 1209 additions and 1207 deletions

View file

@ -10,7 +10,7 @@ use interfaces::{cef_browser_t, cef_browser_host_t, cef_client_t, cef_frame_t};
use interfaces::{cef_request_context_t};
use servo::Browser;
use types::{cef_browser_settings_t, cef_string_t, cef_window_info_t, cef_window_handle_t};
use util::task::spawn_named;
use util::thread::spawn_named;
use window;
use wrappers::CefWrap;
@ -319,4 +319,4 @@ cef_static_method_impls! {
let _request_context: CefRequestContext = _request_context;
browser_host_create(window_info, client, url, true)
}}
}
}

View file

@ -598,7 +598,7 @@ impl CefBrowser {
CefWrap::to_c(message)))
}
}
}
}
impl CefWrap<*mut cef_browser_t> for CefBrowser {
fn to_c(rust_object: CefBrowser) -> *mut cef_browser_t {
@ -755,7 +755,7 @@ impl CefRunFileDialogCallback {
CefWrap::to_c(file_paths)))
}
}
}
}
impl CefWrap<*mut cef_run_file_dialog_callback_t> for CefRunFileDialogCallback {
fn to_c(rust_object: CefRunFileDialogCallback) -> *mut cef_run_file_dialog_callback_t {
@ -914,7 +914,7 @@ impl CefNavigationEntryVisitor {
CefWrap::to_c(total)))
}
}
}
}
impl CefWrap<*mut cef_navigation_entry_visitor_t> for CefNavigationEntryVisitor {
fn to_c(rust_object: CefNavigationEntryVisitor) -> *mut cef_navigation_entry_visitor_t {
@ -1065,7 +1065,7 @@ impl CefPdfPrintCallback {
CefWrap::to_c(ok)))
}
}
}
}
impl CefWrap<*mut cef_pdf_print_callback_t> for CefPdfPrintCallback {
fn to_c(rust_object: CefPdfPrintCallback) -> *mut cef_pdf_print_callback_t {
@ -2540,7 +2540,7 @@ impl CefBrowserHost {
CefWrap::to_c(request_context)))
}
}
}
}
impl CefWrap<*mut cef_browser_host_t> for CefBrowserHost {
fn to_c(rust_object: CefBrowserHost) -> *mut cef_browser_host_t {

View file

@ -169,7 +169,7 @@ impl CefTask {
self.c_object))
}
}
}
}
impl CefWrap<*mut cef_task_t> for CefTask {
fn to_c(rust_object: CefTask) -> *mut cef_task_t {
@ -449,7 +449,7 @@ impl CefTaskRunner {
CefWrap::to_c(threadId)))
}
}
}
}
impl CefWrap<*mut cef_task_runner_t> for CefTaskRunner {
fn to_c(rust_object: CefTaskRunner) -> *mut cef_task_runner_t {
@ -475,4 +475,3 @@ impl CefWrap<*mut cef_task_runner_t> for Option<CefTaskRunner> {
}
}
}

View file

@ -17,4 +17,3 @@ cef_stub_static_method_impls! {
fn cef_task_runner_get_for_current_thread() -> *mut cef_task_runner_t
fn cef_task_runner_get_for_thread(thread_id: cef_thread_id_t) -> *mut cef_task_runner_t
}

View file

@ -18,7 +18,7 @@ use rustc_unicode::str::Utf16Encoder;
use types::{cef_cursor_handle_t, cef_cursor_type_t, cef_rect_t};
use wrappers::CefWrap;
use compositing::compositor_task::{self, CompositorProxy, CompositorReceiver};
use compositing::compositor_thread::{self, CompositorProxy, CompositorReceiver};
use compositing::windowing::{WindowEvent, WindowMethods};
use euclid::point::Point2D;
use euclid::scale_factor::ScaleFactor;
@ -509,11 +509,11 @@ impl WindowMethods for Window {
}
struct CefCompositorProxy {
sender: Sender<compositor_task::Msg>,
sender: Sender<compositor_thread::Msg>,
}
impl CompositorProxy for CefCompositorProxy {
fn send(&self, msg: compositor_task::Msg) {
fn send(&self, msg: compositor_thread::Msg) {
self.sender.send(msg).unwrap();
app_wakeup();
}

View file

@ -5,7 +5,7 @@
//! A windowing implementation using glutin.
use NestedEventLoopListener;
use compositing::compositor_task::{self, CompositorProxy, CompositorReceiver};
use compositing::compositor_thread::{self, CompositorProxy, CompositorReceiver};
#[cfg(feature = "window")]
use compositing::windowing::{MouseWindowEvent, WindowNavigateMsg};
use compositing::windowing::{WindowEvent, WindowMethods};
@ -309,10 +309,10 @@ impl Window {
// broken way we currently call X11 from multiple threads.
//
// On some (most?) X11 implementations, blocking here
// with XPeekEvent results in the paint task getting stuck
// with XPeekEvent results in the paint thread getting stuck
// in XGetGeometry randomly. When this happens the result
// is that until you trigger the XPeekEvent to return
// (by moving the mouse over the window) the paint task
// (by moving the mouse over the window) the paint thread
// never completes and you don't see the most recent
// results.
//
@ -848,7 +848,7 @@ impl WindowMethods for Window {
}
struct GlutinCompositorProxy {
sender: Sender<compositor_task::Msg>,
sender: Sender<compositor_thread::Msg>,
window_proxy: Option<glutin::WindowProxy>,
}
@ -856,7 +856,7 @@ struct GlutinCompositorProxy {
unsafe impl Send for GlutinCompositorProxy {}
impl CompositorProxy for GlutinCompositorProxy {
fn send(&self, msg: compositor_task::Msg) {
fn send(&self, msg: compositor_thread::Msg) {
// Send a message and kick the OS event loop awake.
self.sender.send(msg).unwrap();
if let Some(ref window_proxy) = self.window_proxy {

View file

@ -4,7 +4,7 @@
//! A windowing implementation using gonk interfaces.
use compositing::compositor_task::{self, CompositorProxy, CompositorReceiver};
use compositing::compositor_thread::{self, CompositorProxy, CompositorReceiver};
use compositing::windowing::{WindowEvent, WindowMethods};
use egl::egl;
use egl::egl::EGLConfig;
@ -866,12 +866,12 @@ impl WindowMethods for Window {
}
struct GonkCompositorProxy {
sender: Sender<compositor_task::Msg>,
sender: Sender<compositor_thread::Msg>,
event_sender: Sender<WindowEvent>,
}
impl CompositorProxy for GonkCompositorProxy {
fn send(&self, msg: compositor_task::Msg) {
fn send(&self, msg: compositor_thread::Msg) {
// Send a message and kick the OS event loop awake.
self.sender.send(msg).ok().unwrap();
self.event_sender.send(WindowEvent::Idle).ok().unwrap();