Ejemplo n.º 1
0
        public void Initialise(EventsManagerEventsTab parent,
                               DDNAEventManagerEvent currentEvent,
                               ParameterProvider parameterProvider)
        {
            _parent = parent;

            HashSet <int> existingParameters = FindParametersAlreadyOnEvent(currentEvent.parameters, parameterProvider);

            _addableParameters = FilterParameterList(existingParameters, parameterProvider.Data);
        }
Ejemplo n.º 2
0
        private void OnEnable()
        {
            _authProvider        = new EventsManagerAuthProvider(this);
            _environmentProvider = new EventsManagerEnvironmentProvider();
            _eventProvider       = new EventProvider();
            _parameterProvider   = new ParameterProvider();

            _environmentProvider.OnResponseArrived += ProviderResponseArrived;
            _eventProvider.OnResponseArrived       += ProviderResponseArrived;
            _parameterProvider.OnResponseArrived   += ProviderResponseArrived;

            _eventsTab     = new EventsManagerEventsTab(this, _authProvider, _environmentProvider, _eventProvider, _parameterProvider);
            _parametersTab = new EventsManagerParametersTab(this, _authProvider, _environmentProvider, _eventProvider, _parameterProvider);

            titleContent = new GUIContent(WINDOW_TITLE);

            _authProvider.LoadCacheToken();

            if (EditorPrefs.HasKey(EDITOR_PREFS_API_KEY))
            {
                _apiKey = EditorPrefs.GetString(EDITOR_PREFS_API_KEY);
            }
        }