Esempio n. 1
0
    //****************************************************************************************************
    //
    //****************************************************************************************************

    public bool Show(string rootPath, INTENT paramIntent, FSFilter paramFilter, OnButon onButon)
    {
        if (gameObject.activeSelf == false)
        {
            m_rootPath = rootPath;

            m_onButon = onButon;

            intent = paramIntent;

            filter = (paramFilter != null) ? paramFilter.byval : new FSFilter(FSFilter.LOD.FILE, FSFilter.LOD.FILE, "*");

            m_curFilter = filter.pattern;

            InitInputFields();

            UpdateTitle();


            m_fade.Begin(FADE_TYPE.FADE_IN, FADE_IN_DURATION, OnFadeFinished);

            Update();


            gameObject.SetActive(true);

            EnableButons(false);

            return(true);
        }

        return(false);
    }
Esempio n. 2
0
        public static HashSet <string> getNP(string input, out INTENT userIntent)
        {
            LUISObject LO = analyze(input);

            userIntent = INTENT.Chat;
            Intent[] ins     = LO.intents;
            string   firstIn = ins[0].intent;

            if (firstIn.Equals("FindUser"))
            {
                userIntent = INTENT.FindUser;
            }
            else if (firstIn.Equals("FindProject"))
            {
                userIntent = INTENT.FindProject;
            }
            else if (firstIn.Equals("FormTeam"))
            {
                userIntent = INTENT.FindTeam;
            }


            KEntity[]        ens    = LO.entities;
            HashSet <string> result = new HashSet <string>();

            if (ens == null || ens.Length == 0)
            {
                return(result);
            }

            foreach (KEntity ke in ens)
            {
                result.Add(ke.entity);
            }
            return(result);
        }