Auto merge of #7246 - glennw:platform-ua, r=larsbergstrom

Add a simple method to emulate a platform UA (e.g. pretend a desktop build is an android UA).



<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7246)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2015-08-17 22:44:38 -06:00
commit f340900c38
5 changed files with 44 additions and 21 deletions

View file

@ -28,10 +28,7 @@ pub fn Platform() -> DOMString {
}
pub fn UserAgent() -> DOMString {
match opts::get().user_agent {
Some(ref user_agent) => user_agent.clone(),
None => "".to_owned(),
}
opts::get().user_agent.clone()
}
pub fn AppVersion() -> DOMString {