mirror of
https://github.com/gnh1201/welsonjs.git
synced 2024-11-26 07:21:43 +00:00
Update chrome.js
This commit is contained in:
parent
c6d55cd1fa
commit
eb389d34c7
|
@ -687,13 +687,14 @@ var ChromeObject = function() {
|
|||
};
|
||||
|
||||
this.setTitle = function(title) {
|
||||
var i = 0, repeat = 2;
|
||||
|
||||
if (this.debuggingPort > 0) {
|
||||
while (i < repeat) {
|
||||
this.evaluate('document.title = ' + this.__escape(title));
|
||||
i++;
|
||||
}
|
||||
if (!(this.debuggingPort > 0))
|
||||
return;
|
||||
|
||||
var i = 0, k = 5;
|
||||
while (i < k && title != this.getTitle()) {
|
||||
sleep(1000);
|
||||
this.evaluate('document.title = ' + this.__escape(title));
|
||||
i++;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user