Removed some sources of panic from script thread and devtools, using Option values instead to indicate when a pipeline context is missing where appropriate. Additionally, removed erroneous method get_browsing_context.

This commit is contained in:
David Raifaizen 2016-07-25 20:34:47 -04:00
parent 4b78b9adab
commit 2475dc1d21
7 changed files with 89 additions and 54 deletions

View file

@ -53,7 +53,10 @@ pub enum WebDriverJSValue {
#[derive(Deserialize, Serialize)]
pub enum WebDriverJSError {
Timeout,
UnknownType
UnknownType,
/// Occurs when handler received an event message for a layout channel that is not
/// associated with the current script thread
BrowsingContextNotFound
}
pub type WebDriverJSResult = Result<WebDriverJSValue, WebDriverJSError>;