コード例 #1
0
    public void OpenWindow(int tabIndex)
    {
        if (uiManager == null)
        {
            uiManager = GameObject.Find("UIManager").GetComponent <UIManager_v5>();
        }
        uiManager.CloseAllWindows();
        gameObject.SetActive(true);
        DispensaryUIPanel dispensaryPanel = gameObject.GetComponent <DispensaryUIPanel>();

        if (dispensaryPanel != null)
        {
            dispensaryPanel.OnWindowOpen(tabIndex);
        }
        CompanyUIPanel companyPanel = gameObject.GetComponent <CompanyUIPanel>();

        if (companyPanel != null)
        {
            companyPanel.OnWindowOpen(tabIndex);
        }
        CalendarUIPanel calendarPanel = gameObject.GetComponent <CalendarUIPanel>();

        if (calendarPanel != null)
        {
            calendarPanel.OpenCalendar();
        }
        windowOpen = true;
    }
コード例 #2
0
 public void CreateList()
 {
     if (windowOpen)
     {
         DispensaryUIPanel dispensaryUIPanel = gameObject.GetComponent <DispensaryUIPanel>();
         if (dispensaryUIPanel != null)
         {
             dispensaryUIPanel.CreateList(searchBar.GetText());
         }
         StoreObjectUIPanel storeObjectPanel = gameObject.GetComponent <StoreObjectUIPanel>();
         if (storeObjectPanel != null)
         {
             storeObjectPanel.CreateStoreObjectsList(searchBar.GetText());
         }
     }
 }
コード例 #3
0
 public void WindowToggle(int index)
 {
     if (index == -1)
     {
         CloseWindow();
         return;
     }
     if (windowOpen)
     {
         DispensaryUIPanel dispensaryPanel = gameObject.GetComponent <DispensaryUIPanel>();
         if (dispensaryPanel != null)
         {
             if (index != dispensaryPanel.currentTabIndex)
             {
                 OpenWindow(index);
                 return;
             }
             else
             {
                 CloseWindow();
                 return;
             }
         }
         CompanyUIPanel companyPanel = gameObject.GetComponent <CompanyUIPanel>();
         if (companyPanel != null)
         {
             if (index != companyPanel.currentTabIndex)
             {
                 OpenWindow(index);
                 return;
             }
             else
             {
                 CloseWindow();
                 return;
             }
         }
         CloseWindow();
     }
     else
     {
         OpenWindow(index);
     }
 }
コード例 #4
0
    public void Search()
    {
        DispensaryUIPanel dispensaryPanel = gameObject.GetComponent <DispensaryUIPanel>();

        if (dispensaryPanel != null)
        {
            dispensaryPanel.Search(searchBar.GetText());
        }
        CompanyUIPanel companyPanel = gameObject.GetComponent <CompanyUIPanel>();

        if (companyPanel != null)
        {
        }
        StoreObjectUIPanel storeObjectPanel = gameObject.GetComponent <StoreObjectUIPanel>();

        if (storeObjectPanel != null)
        {
            storeObjectPanel.CreateStoreObjectsList(searchBar.GetText());
        }
    }