mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-21 01:05:45 +00:00
Bug 1345997 - Add a check for the inspector toolbox when checking if the grid inspector or box model is visible. r=jdescottes
MozReview-Commit-ID: 5Ve2COO5Vkc
This commit is contained in:
parent
83cdc02ec0
commit
143314a407
@ -78,8 +78,8 @@ BoxModel.prototype = {
|
||||
* Returns true if the computed or layout panel is visible, and false otherwise.
|
||||
*/
|
||||
isPanelVisible() {
|
||||
return this.inspector.toolbox.currentToolId === "inspector" &&
|
||||
this.inspector.sidebar &&
|
||||
return this.inspector.toolbox && this.inspector.sidebar &&
|
||||
this.inspector.toolbox.currentToolId === "inspector" &&
|
||||
(this.inspector.sidebar.getCurrentTabID() === "layoutview" ||
|
||||
this.inspector.sidebar.getCurrentTabID() === "computedview");
|
||||
},
|
||||
|
@ -201,8 +201,8 @@ GridInspector.prototype = {
|
||||
* Returns true if the layout panel is visible, and false otherwise.
|
||||
*/
|
||||
isPanelVisible() {
|
||||
return this.inspector.toolbox.currentToolId === "inspector" &&
|
||||
this.inspector.sidebar &&
|
||||
return this.inspector.toolbox && this.inspector.sidebar &&
|
||||
this.inspector.toolbox.currentToolId === "inspector" &&
|
||||
this.inspector.sidebar.getCurrentTabID() === "layoutview";
|
||||
},
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user