Implement Navigator.appVersion(#5409)

This commit is contained in:
Deokjin Kim 2015-03-30 22:00:59 +09:00
parent 1bd8e18d92
commit c0e691b08d
7 changed files with 14 additions and 16 deletions

View file

@ -54,5 +54,9 @@ impl<'a> NavigatorMethods for JSRef<'a, Navigator> {
fn UserAgent(self) -> DOMString {
navigatorinfo::UserAgent()
}
fn AppVersion(self) -> DOMString {
navigatorinfo::AppVersion()
}
}

View file

@ -33,3 +33,7 @@ pub fn UserAgent() -> DOMString {
None => "".to_owned(),
}
}
pub fn AppVersion() -> DOMString {
"4.0".to_owned()
}

View file

@ -19,7 +19,7 @@ Navigator implements NavigatorID;
interface NavigatorID {
readonly attribute DOMString appCodeName; // constant "Mozilla"
readonly attribute DOMString appName;
//readonly attribute DOMString appVersion;
readonly attribute DOMString appVersion;
readonly attribute DOMString platform;
readonly attribute DOMString product; // constant "Gecko"
boolean taintEnabled(); // constant false

View file

@ -55,5 +55,9 @@ impl<'a> WorkerNavigatorMethods for JSRef<'a, WorkerNavigator> {
fn UserAgent(self) -> DOMString {
navigatorinfo::UserAgent()
}
fn AppVersion(self) -> DOMString {
navigatorinfo::AppVersion()
}
}