예제 #1
0
    void updateCompletedList(bool changeOfTab)
    {
        InvestigationManager im             = InvestigationManager.GetInstance();
        List <Investigation> investigations = im.getCompletedInvestigations();

        if (changeOfTab && investigations.Count > 0)
        {
            selectedId = investigations [0].getID();
        }
        else if (investigations.Count == 0)
        {
            selectedId = -1;
        }

        showInvestigationsList(investigations);
    }
예제 #2
0
    void updateCompletedInfo()
    {
        InvestigationManager im             = InvestigationManager.GetInstance();
        List <Investigation> investigations = im.getCompletedInvestigations();

        if (investigations.Count == 0)
        {
            investigationButton.interactable = false;
            investigationButtonText.text     = Dictionary.getString("NO_RESEARCH_COMPLETED");

            nameText.text        = "";
            priceText.text       = "";
            descriptionText.text = "";
        }
        else
        {
            Investigation selectedInvest = im.getInvestigation(selectedId);
            nameText.text                    = selectedInvest.getName();
            priceText.text                   = " " + Dictionary.getString("COST") + " " + selectedInvest.getCost();
            descriptionText.text             = selectedInvest.getDesc();
            investigationButton.interactable = false;
            investigationButtonText.text     = Dictionary.getString("RESEARCH_COMPLETED");
        }
    }