diff options
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 52 |
1 files changed, 39 insertions, 13 deletions
@@ -174,7 +174,9 @@ int main(int argc, char *argv[]) { /**************************************************************************** ****************************************************************************/ -void DoExit(int code) { +void +DoExit(int code) +{ Destroy(); if(configPath) { @@ -192,7 +194,9 @@ void DoExit(int code) { /**************************************************************************** ****************************************************************************/ -void EventLoop() { +void +EventLoop() +{ XEvent event; while(!shouldExit) { @@ -203,7 +207,9 @@ void EventLoop() { /**************************************************************************** ****************************************************************************/ -void OpenConnection() { +void +OpenConnection() +{ display = JXOpenDisplay(displayString); if(!display) { @@ -231,7 +237,9 @@ void OpenConnection() { /**************************************************************************** ****************************************************************************/ -void StartupConnection() { +void +StartupConnection() +{ XSetWindowAttributes attr; int temp; @@ -276,20 +284,26 @@ void StartupConnection() { /**************************************************************************** ****************************************************************************/ -void CloseConnection() { +void +CloseConnection() +{ JXFlush(display); JXCloseDisplay(display); } /**************************************************************************** ****************************************************************************/ -void ShutdownConnection() { +void +ShutdownConnection() +{ CloseConnection(); } /**************************************************************************** ****************************************************************************/ -void HandleExit() { +void +HandleExit() +{ signal(SIGTERM, HandleExit); signal(SIGINT, HandleExit); signal(SIGHUP, HandleExit); @@ -299,7 +313,9 @@ void HandleExit() { /**************************************************************************** * This is called before the X connection is opened. ****************************************************************************/ -void Initialize() { +void +Initialize() +{ InitializeBorders(); InitializeClients(); InitializeClock(); @@ -332,7 +348,9 @@ void Initialize() { /**************************************************************************** * This is called after the X connection is opened. ****************************************************************************/ -void Startup() { +void +Startup() +{ /* This order is important. */ @@ -393,7 +411,9 @@ void Startup() { /**************************************************************************** * This is called before the X connection is closed. ****************************************************************************/ -void Shutdown() { +void +Shutdown() +{ /* This order is important. */ @@ -434,7 +454,9 @@ void Shutdown() { * This is called after the X connection is closed. * Note that it is possible for this to be called more than once. ****************************************************************************/ -void Destroy() { +void +Destroy() +{ DestroyBorders(); DestroyClients(); DestroyClock(); @@ -467,7 +489,9 @@ void Destroy() { /**************************************************************************** * Send _JWM_RESTART to the root window. ****************************************************************************/ -void SendRestart() { +void +SendRestart() +{ XEvent event; @@ -488,7 +512,9 @@ void SendRestart() { /**************************************************************************** * Send _JWM_EXIT to the root window. ****************************************************************************/ -void SendExit() { +void +SendExit() +{ XEvent event; |