mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 668760 - Factor out method to get weave engine (r=mbrubeck)
This commit is contained in:
parent
aed526341f
commit
57e277cdee
@ -1427,16 +1427,22 @@
|
||||
|
||||
<field name="scrollBoxObject">this._children.scrollBoxObject</field>
|
||||
|
||||
<method name="_getWeaveEngine">
|
||||
<body><![CDATA[
|
||||
// Return null if the Weave isn't ready
|
||||
if (document.getElementById("cmd_remoteTabs").getAttribute("disabled") == "true")
|
||||
return null;
|
||||
if (Weave.Status.checkSetup() == Weave.CLIENT_NOT_CONFIGURED)
|
||||
return null;
|
||||
|
||||
return Weave.Engines.get("tabs");
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
<method name="_getRemoteTabs">
|
||||
<body><![CDATA[
|
||||
// Don't do anything if the Weave isn't ready
|
||||
if (document.getElementById("cmd_remoteTabs").getAttribute("disabled") == "true")
|
||||
return [];
|
||||
if (Weave.Status.checkSetup() == Weave.CLIENT_NOT_CONFIGURED)
|
||||
return [];
|
||||
|
||||
// Don't do anything if the tabs engine isn't ready
|
||||
let engine = Weave.Engines.get("tabs");
|
||||
let engine = this._getWeaveEngine();
|
||||
if (!engine)
|
||||
return [];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user