Ejemplo n.º 1
0
 /// <inheritdoc />
 public override string ToString()
 {
     return(string.Join("+", Chord.Concat(Enumerable.Repeat(TriggerKey, 1))));
 }
Ejemplo n.º 2
0
 /// <summary>
 ///     A chainable builder method to simplify chord creation. Used along with <see cref="TriggeredBy" />,
 ///     <see cref="With" />, <see cref="Control" />, <see cref="Shift" />, <see cref="Alt" />.
 /// </summary>
 /// <param name="key"></param>
 public CXHotkeyCombination With(Keys key)
 {
     return(new CXHotkeyCombination(TriggerKey, Chord.Concat(Enumerable.Repeat(key, 1))));
 }
Ejemplo n.º 3
0
 public override int GetHashCode()
 {
     return(Chord.GetHashCode() ^
            (int)TriggerKey);
 }
Ejemplo n.º 4
0
 private CXHotkeyCombination(Keys triggerKey, Chord chord)
 {
     TriggerKey = triggerKey;
     _chord     = chord;
 }
Ejemplo n.º 5
0
 protected bool Equals(CXHotkeyCombination other)
 {
     return
         (TriggerKey == other.TriggerKey &&
          Chord.Equals(other.Chord));
 }