Пример #1
0
        public void ClearButtonEventHandler(
            string instanceName, ButtonEventHandlers.Type type)
        {
            int instId = SearchInstanceId(GetStringId(instanceName));

            if (instId >= 0)
            {
                ClearButtonEventHandler(instId, type);
                return;
            }

            if (m_buttonEventHandlersByFullName == null)
            {
                return;
            }

            ButtonEventHandlers handlers =
                m_buttonEventHandlersByFullName[instanceName];

            if (handlers == null)
            {
                return;
            }

            handlers.Clear(type);
        }
Пример #2
0
 public void SetHandlers(ButtonEventHandlers handler)
 {
     if (m_handler == null)
     {
         m_handler = new ButtonEventHandlers();
     }
     else
     {
         m_handler.Clear();
     }
     m_handler.Add(handler);
 }
Пример #3
0
        public void ClearButtonEventHandler(int instId)
        {
            if (instId < 0 || instId >= m_instances.Length)
            {
                return;
            }

            ButtonEventHandlers handlers = m_buttonEventHandlers[instId];

            if (handlers == null)
            {
                return;
            }

            handlers.Clear();
        }
Пример #4
0
        public void ClearButtonEventHandler(int instId)
        {
            if (instId < 0 || instId >= m_instances.Length)
            {
                return;
            }

            ButtonEventHandlers handlers = m_buttonEventHandlers[instId];

            if (handlers == null)
            {
                return;
            }

            handlers.Clear();

            Button button = SearchButtonInstanceByInstanceId(instId);

            if (button != null)
            {
                button.SetHandlers(handlers);
            }
        }