<template>
  <!-- 桌面 -->
  <div
    id="sds-desktop"
    :style="{ display: display }"
  >
    <Menu></Menu>
    <Shortcut :defaultZIndex="defaultZIndex"></Shortcut>
    <FixWindow
      :defaultZIndex="defaultZIndex"
      :fixWindowData="fixWindowData"
      :maskIsShow="maskIsShow"
    ></FixWindow>
    <NotifyTrayPanel></NotifyTrayPanel>
    <NotifyTrayPanelDetail
      :defaultZIndex="defaultZIndex"
      :notifyTrayPanelDetailData="notifyTrayPanelDetailData"
    ></NotifyTrayPanelDetail>
    <NotifyShowall
      :defaultZIndex="defaultZIndex"
      :notifyShowAllData="notifyShowAllData"
    ></NotifyShowall>
    <NotifySetting
      :defaultZIndex="defaultZIndex"
      :notifySettingData="notifySettingData"
    ></NotifySetting>
    <UserTrayPanel></UserTrayPanel>
    <UserSetting
      :defaultZIndex="defaultZIndex"
      :userSettingData="userSettingData"
    ></UserSetting>
    <UserAbout :defaultZIndex="defaultZIndex"></UserAbout>
    <SearchInput :searchInputData="searchInputData"  :defaultZIndex="defaultZIndex"></SearchInput>
  </div>
</template>

<script>
import Menu from "./Menu";
import Shortcut from "./Shortcut";
import FixWindow from "./FixWindow";
import NotifyTrayPanel from "./NotifyTrayPanel";
import NotifyTrayPanelDetail from "./NotifyTrayPanelDetail";
import NotifyShowall from "./NotifyShowall";
import NotifySetting from "./NotifySetting";
import UserTrayPanel from "./UserTrayPanel";
import UserSetting from "./UserSetting";
import UserAbout from "./UserAbout";
import SearchInput from "./SearchInput";

export default {
  props: [
    "defaultZIndex",
    "userSettingData",
    "fixWindowData",
    "notifyTrayPanelDetailData",
    "notifySettingData",
    "notifyShowAllData",
    "searchInputData",
    "maskIsShow"
  ],
  data() {
    return {
      display: "block",
    };
  },
  created(){

  },
  mounted() {
    this.$bus.on("hiddenOrShowOtherWindow", this.hiddenOrShowThisWindow);
  },
  methods: {
    //是否隐藏本页面
    hiddenOrShowThisWindow(bol) {
      if (bol) {
        this.display = "none";
      } else {
        this.display = "block";
      }
    },
  },
  watch: {},
  components: {
    Menu,
    Shortcut,
    FixWindow,
    NotifyTrayPanel,
    NotifyTrayPanelDetail,
    NotifyShowall,
    NotifySetting,
    UserTrayPanel,
    UserSetting,
    UserAbout,
    SearchInput,
  },
  name: "Desktop",
};
</script>
