Home | History | Annotate | Download | only in ui

Lines Matching defs:Behavior

169     const Behavior* behavior;
170 if (getKeyBehavior(keyCode, metaState, &key, &behavior)) {
171 result = behavior->character;
186 const Behavior* behavior;
187 if (getKeyBehavior(keyCode, metaState, &key, &behavior)) {
188 if (behavior->fallbackKeyCode) {
189 outFallbackAction->keyCode = behavior->fallbackKeyCode;
190 outFallbackAction->metaState = metaState & ~behavior->metaState;
208 // Try to find the most general behavior that maps to this character.
209 // For example, the base key behavior will usually be last in the list.
210 // However, if we find a perfect meta state match for one behavior then use that one.
211 for (const Behavior* behavior = key->firstBehavior; behavior; behavior = behavior->next) {
212 if (behavior->character) {
214 if (behavior->character == chars[i]) {
215 result = behavior->character;
216 if ((behavior->metaState & metaState) == behavior->metaState) {
276 const Key** outKey, const Behavior** outBehavior) const {
279 const Behavior* behavior = key->firstBehavior;
280 while (behavior) {
281 if ((behavior->metaState & metaState) == behavior->metaState) {
283 *outBehavior = behavior;
286 behavior = behavior->next;
300 // Try to find the most general behavior that maps to this character.
301 // For example, the base key behavior will usually be last in the list.
302 const Behavior* found = NULL;
303 for (const Behavior* behavior = key->firstBehavior; behavior; behavior = behavior->next) {
304 if (behavior->character == ch) {
305 found = behavior;
441 Behavior* behavior = firstBehavior;
442 while (behavior) {
443 Behavior* next = behavior->next;
444 delete behavior;
445 behavior = next;
450 // --- KeyCharacterMap::Behavior ---
452 KeyCharacterMap::Behavior::Behavior() :
635 // Parse behavior after the colon.
638 Behavior behavior;
657 behavior.character = character;
673 LOGE("%s: Invalid key code label for fallback behavior, got '%s'.",
683 behavior.fallbackKeyCode = keyCode;
686 LOGE("%s: Expected a key behavior after ':'.",
695 // Add the behavior.
706 key->label = behavior.character;
717 key->number = behavior.character;
723 for (Behavior* b = key->firstBehavior; b; b = b->next) {
725 LOGE("%s: Duplicate key behavior for modifier.",
730 Behavior* newBehavior = new Behavior(behavior);