Ejemplo n.º 1
0
 public string GetGestureName(string action, string culture)
 {
     CulturalPair pair = new CulturalPair(action, culture);
     string value;
     if (culturalGestures.TryGetValue(pair, out value)) {
         return value;
     }
     return defaultGestures[action];
 }
Ejemplo n.º 2
0
        public string GetGestureName(string action, string culture)
        {
            CulturalPair pair = new CulturalPair(action, culture);
            string       value;

            if (culturalGestures.TryGetValue(pair, out value))
            {
                return(value);
            }
            return(defaultGestures[action]);
        }
Ejemplo n.º 3
0
        public void AddCultureGesture(string action, string culture, string gestureName)
        {
            if (!defaultGestures.ContainsKey(action)) {
                AddDefaultGesture(action, gestureName);
            }

            CulturalPair cultPair = new CulturalPair(action, culture);
            try {
                culturalGestures.Add(cultPair, gestureName);
            }
            catch (ArgumentException) {
                culturalGestures[cultPair] = gestureName;
            }
        }
Ejemplo n.º 4
0
        public void AddCultureGesture(string action, string culture, string gestureName)
        {
            if (!defaultGestures.ContainsKey(action))
            {
                AddDefaultGesture(action, gestureName);
            }

            CulturalPair cultPair = new CulturalPair(action, culture);

            try {
                culturalGestures.Add(cultPair, gestureName);
            }
            catch (ArgumentException) {
                culturalGestures[cultPair] = gestureName;
            }
        }
Ejemplo n.º 5
0
        public override bool Equals(object obj)
        {
            if (obj == null)
            {
                return(false);
            }

            CulturalPair pair = (CulturalPair)obj;

            if ((System.Object)pair == null)
            {
                return(false);
            }

            return(this.action.Equals(pair.action) && this.culture.Equals(pair.culture));
        }