Ejemplo n.º 1
0
/** Validate actions. */
void ValidateActions(const ActionType *actions)
{
   const ActionType *ap;
   for(ap = actions; ap; ap = ap->next) {
      if(ap->action && !strncmp(ap->action, "root:", 5)) {
         const int bindex = GetRootMenuIndexFromString(&ap->action[5]);
         if(JUNLIKELY(!IsRootMenuDefined(bindex))) {
            Warning(_("action: root menu \"%s\" not defined"),
                    &ap->action[5]);
         }
      }
   }
}
Ejemplo n.º 2
0
Archivo: key.c Proyecto: kuailexs/jwm
/** Validate key bindings. */
void ValidateKeys(void)
{
    KeyNode *kp;
    for(kp = bindings; kp; kp = kp->next) {
        if((kp->key & 0xFF) == KEY_ROOT && kp->command) {
            const int bindex = GetRootMenuIndexFromString(kp->command);
            if(JUNLIKELY(!IsRootMenuDefined(bindex))) {
                Warning(_("key binding: root menu \"%s\" not defined"),
                        kp->command);
            }
        }
    }
}