aboutsummaryrefslogtreecommitdiff
path: root/src/key.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/key.c')
-rw-r--r--src/key.c66
1 files changed, 49 insertions, 17 deletions
diff --git a/src/key.c b/src/key.c
index f14ad62..5cedd3d 100644
--- a/src/key.c
+++ b/src/key.c
@@ -62,7 +62,9 @@ static void GrabKey(KeyNode *np);
/***************************************************************************
***************************************************************************/
-void InitializeKeys() {
+void
+InitializeKeys()
+{
bindings = NULL;
modifierMask = 0;
@@ -71,7 +73,9 @@ void InitializeKeys() {
/***************************************************************************
***************************************************************************/
-void StartupKeys() {
+void
+StartupKeys()
+{
KeyNode *np;
int x;
@@ -121,7 +125,9 @@ void StartupKeys() {
/***************************************************************************
***************************************************************************/
-void ShutdownKeys() {
+void
+ShutdownKeys()
+{
ClientNode *np;
int layer;
@@ -138,7 +144,9 @@ void ShutdownKeys() {
/***************************************************************************
***************************************************************************/
-void DestroyKeys() {
+void
+DestroyKeys()
+{
KeyNode *np;
@@ -155,7 +163,9 @@ void DestroyKeys() {
/***************************************************************************
***************************************************************************/
-void GrabKey(KeyNode *np) {
+void
+GrabKey(KeyNode *np)
+{
TrayType *tp;
int x;
@@ -186,7 +196,9 @@ void GrabKey(KeyNode *np) {
/***************************************************************************
***************************************************************************/
-KeyType GetKey(const XKeyEvent *event) {
+KeyType
+GetKey(const XKeyEvent *event)
+{
KeyNode *np;
unsigned int state;
@@ -204,7 +216,9 @@ KeyType GetKey(const XKeyEvent *event) {
/***************************************************************************
***************************************************************************/
-void RunKeyCommand(const XKeyEvent *event) {
+void
+RunKeyCommand(const XKeyEvent *event)
+{
KeyNode *np;
@@ -219,7 +233,9 @@ void RunKeyCommand(const XKeyEvent *event) {
/***************************************************************************
***************************************************************************/
-void ShowKeyMenu(const XKeyEvent *event) {
+void
+ShowKeyMenu(const XKeyEvent *event)
+{
KeyNode *np;
int button;
@@ -238,7 +254,9 @@ void ShowKeyMenu(const XKeyEvent *event) {
/***************************************************************************
***************************************************************************/
-int ShouldGrab(KeyType key) {
+int
+ShouldGrab(KeyType key)
+{
switch(key & 0xFF) {
case KEY_NEXT:
case KEY_NEXT_STACKED:
@@ -267,7 +285,9 @@ int ShouldGrab(KeyType key) {
/***************************************************************************
***************************************************************************/
-void GrabKeys(ClientNode *np) {
+void
+GrabKeys(ClientNode *np)
+{
KeyNode *kp;
@@ -282,7 +302,9 @@ void GrabKeys(ClientNode *np) {
/***************************************************************************
***************************************************************************/
-unsigned int GetModifierMask(KeySym key) {
+unsigned int
+GetModifierMask(KeySym key)
+{
KeyCode temp;
int x;
@@ -302,7 +324,9 @@ unsigned int GetModifierMask(KeySym key) {
/***************************************************************************
***************************************************************************/
-unsigned int ParseModifierString(const char *str) {
+unsigned int
+ParseModifierString(const char *str)
+{
unsigned int mask;
int x;
@@ -343,7 +367,9 @@ unsigned int ParseModifierString(const char *str) {
/***************************************************************************
***************************************************************************/
-KeySym ParseKeyString(const char *str) {
+KeySym
+ParseKeyString(const char *str)
+{
KeySym symbol;
@@ -358,8 +384,10 @@ KeySym ParseKeyString(const char *str) {
/***************************************************************************
***************************************************************************/
-void InsertBinding(KeyType key, const char *modifiers,
- const char *stroke, const char *code, const char *command) {
+void
+InsertBinding(KeyType key, const char *modifiers,
+ const char *stroke, const char *code, const char *command)
+{
KeyNode *np;
unsigned int mask;
@@ -439,7 +467,9 @@ void InsertBinding(KeyType key, const char *modifiers,
/***************************************************************************
***************************************************************************/
-void ValidateKeys() {
+void
+ValidateKeys()
+{
KeyNode *kp;
int bindex;
@@ -456,7 +486,9 @@ void ValidateKeys() {
}
/** Return true if the key event matches any switching key or its modifiers. */
-int Switching(const XKeyEvent *event) {
+int
+Switching(const XKeyEvent *event)
+{
KeyNode *np;
KeySym keysym;
KeyType key;