]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - keys.c
removed detection of GL_NV_texture_shader extension which was previously used for...
[xonotic/darkplaces.git] / keys.c
diff --git a/keys.c b/keys.c
index 97070dd684fac8a5b9eef7c112d398910f8241b6..bec44c4c754e57eb15e3a075de325da4600b2746 100644 (file)
--- a/keys.c
+++ b/keys.c
@@ -465,7 +465,7 @@ Key_Console (int key, char ascii)
                if (keydown[K_CTRL])
                        con_backscroll = 0;
                else
-                       key_linepos = strlen(key_lines[edit_line]);
+                       key_linepos = (int)strlen(key_lines[edit_line]);
                return;
        }
 
@@ -811,13 +811,13 @@ Key_Init (void)
 //
 // register our functions
 //
-       Cmd_AddCommand ("in_bind", Key_In_Bind_f);
-       Cmd_AddCommand ("in_unbind", Key_In_Unbind_f);
-       Cmd_AddCommand ("in_bindmap", Key_In_Bindmap_f);
+       Cmd_AddCommand ("in_bind", Key_In_Bind_f, "binds a command to the specified key in the selected bindmap");
+       Cmd_AddCommand ("in_unbind", Key_In_Unbind_f, "removes command on the specified key in the selected bindmap");
+       Cmd_AddCommand ("in_bindmap", Key_In_Bindmap_f, "selects active foreground and background (used only if a key is not bound in the foreground) bindmaps for typing");
 
-       Cmd_AddCommand ("bind", Key_Bind_f);
-       Cmd_AddCommand ("unbind", Key_Unbind_f);
-       Cmd_AddCommand ("unbindall", Key_Unbindall_f);
+       Cmd_AddCommand ("bind", Key_Bind_f, "binds a command to the specified key in bindmap 0");
+       Cmd_AddCommand ("unbind", Key_Unbind_f, "removes a command on the specified key in bindmap 0");
+       Cmd_AddCommand ("unbindall", Key_Unbindall_f, "removes all commands from all keys in all bindmaps (leaving only shift-escape and escape)");
 }
 
 const char *Key_GetBind (int key)
@@ -920,10 +920,7 @@ Key_Event (int key, char ascii, qboolean down)
                                MR_ToggleMenu_f ();
                                break;
                        default:
-                               if(UI_Callback_IsSlotUsed(key_dest - 3))
-                                       UI_Callback_KeyDown (key, ascii);
-                               else
-                                       Con_Printf ("Key_Event: Bad key_dest\n");
+                               Con_Printf ("Key_Event: Bad key_dest\n");
                }
                return;
        }
@@ -985,10 +982,7 @@ Key_Event (int key, char ascii, qboolean down)
                        }
                        break;
                default:
-                       if(UI_Callback_IsSlotUsed(key_dest - 3))
-                               UI_Callback_KeyDown (key, ascii);
-                       else
-                               Con_Printf ("Key_Event: Bad key_dest\n");
+                       Con_Printf ("Key_Event: Bad key_dest\n");
        }
 }