Commit bd68cc6c authored by Nicolas Chevobbe's avatar Nicolas Chevobbe
Browse files

Bug 1765748 - [devtools] Remove unused SplitView#isLandscape . r=ochameau.

This allows us to remove the `_mql` property as well as the `LANDSCAPE_MEDIA_QUERY`
const.

Differential Revision: https://phabricator.services.mozilla.com/D144264
parent 54dc8da6
Loading
Loading
Loading
Loading
+0 −16
Original line number Diff line number Diff line
@@ -11,9 +11,6 @@ const { KeyCodes } = require("devtools/client/shared/keycodes");

const EXPORTED_SYMBOLS = ["SplitView"];

/* this must be kept in sync with CSS (ie. splitview.css) */
const LANDSCAPE_MEDIA_QUERY = "(min-width: 701px)";

var bindings = new WeakMap();

class SplitView {
@@ -36,10 +33,6 @@ class SplitView {
    this._activeSummary = null;
    this._filter = null;

    this._mql = root.ownerDocument.defaultView.matchMedia(
      LANDSCAPE_MEDIA_QUERY
    );

    // items list focus and search-on-type handling
    this._nav.addEventListener("keydown", event => {
      function getFocusedItemWithin(nav) {
@@ -96,15 +89,6 @@ class SplitView {
    });
  }

  /**
   * Retrieve whether the UI currently has a landscape orientation.
   *
   * @return boolean
   */
  get isLandscape() {
    return this._mql.matches;
  }

  /**
   * Retrieve the root element.
   *