Make sure all uicb_ functions have doxygen annotations.

Also refactor some indentation while I'm there.
This commit is contained in:
Aldo Cortesi 2007-12-19 14:39:59 +11:00 committed by Julien Danjou
parent cbf5c474c1
commit 980afac1cf
7 changed files with 91 additions and 4 deletions

View File

@ -660,6 +660,8 @@ uicb_setborder(int screen, char *arg)
} }
/** Swap current with next client /** Swap current with next client
* \param screen Screen ID
* \param arg nothing
* \ingroup ui_callback * \ingroup ui_callback
*/ */
void void
@ -681,6 +683,8 @@ uicb_client_swapnext(int screen, char *arg __attribute__ ((unused)))
} }
/** Swap current with previous client /** Swap current with previous client
* \param screen Screen ID
* \param arg nothing
* \ingroup ui_callback * \ingroup ui_callback
*/ */
void void

View File

@ -106,6 +106,11 @@ focus_get_latest_client_for_tag(int screen, Tag *t)
return NULL; return NULL;
} }
/** Jump in focus history stack
* \param screen Screen ID
* \param arg Integer argument
* \ingroup ui_callback
*/
void void
uicb_focus_history(int screen, char *arg) uicb_focus_history(int screen, char *arg)
{ {

View File

@ -99,6 +99,11 @@ get_current_layout(int screen)
return NULL; return NULL;
} }
/** Send focus to next client in stack
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_focusnext(int screen, char *arg __attribute__ ((unused))) uicb_client_focusnext(int screen, char *arg __attribute__ ((unused)))
{ {
@ -116,6 +121,11 @@ uicb_client_focusnext(int screen, char *arg __attribute__ ((unused)))
} }
} }
/** Send focus to previous client in stack
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_focusprev(int screen, char *arg __attribute__ ((unused))) uicb_client_focusprev(int screen, char *arg __attribute__ ((unused)))
{ {
@ -224,6 +234,11 @@ saveawesomeprops(int screen)
p_delete(&prop); p_delete(&prop);
} }
/** Set layout for tag
* \param screen Screen ID
* \param arg Layout specifier
* \ingroup ui_callback
*/
void void
uicb_tag_setlayout(int screen, char *arg) uicb_tag_setlayout(int screen, char *arg)
{ {
@ -277,6 +292,11 @@ maximize(int x, int y, int w, int h, int screen)
arrange(screen); arrange(screen);
} }
/** Toggle maximize for client
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_togglemax(int screen, char *arg __attribute__ ((unused))) uicb_client_togglemax(int screen, char *arg __attribute__ ((unused)))
{ {
@ -291,6 +311,11 @@ uicb_client_togglemax(int screen, char *arg __attribute__ ((unused)))
p_delete(&si); p_delete(&si);
} }
/** Toggle vertical maximize for client
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_toggleverticalmax(int screen, char *arg __attribute__ ((unused))) uicb_client_toggleverticalmax(int screen, char *arg __attribute__ ((unused)))
{ {
@ -309,6 +334,11 @@ uicb_client_toggleverticalmax(int screen, char *arg __attribute__ ((unused)))
} }
/** Toggle horizontal maximize for client
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_togglehorizontalmax(int screen, char *arg __attribute__ ((unused))) uicb_client_togglehorizontalmax(int screen, char *arg __attribute__ ((unused)))
{ {
@ -326,6 +356,11 @@ uicb_client_togglehorizontalmax(int screen, char *arg __attribute__ ((unused)))
p_delete(&si); p_delete(&si);
} }
/** Zoom client
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_zoom(int screen, char *arg __attribute__ ((unused))) uicb_client_zoom(int screen, char *arg __attribute__ ((unused)))
{ {

22
mouse.c
View File

@ -30,6 +30,11 @@
extern awesome_config globalconf; extern awesome_config globalconf;
/** Move client with mouse
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_movemouse(int screen, char *arg __attribute__ ((unused))) uicb_client_movemouse(int screen, char *arg __attribute__ ((unused)))
{ {
@ -49,14 +54,20 @@ uicb_client_movemouse(int screen, char *arg __attribute__ ((unused)))
else else
restack(screen); restack(screen);
si = get_screen_info(c->screen, globalconf.screens[screen].statusbar, &globalconf.screens[screen].padding); si = get_screen_info(c->screen,
globalconf.screens[screen].statusbar,
&globalconf.screens[screen].padding);
ocx = nx = c->x; ocx = nx = c->x;
ocy = ny = c->y; ocy = ny = c->y;
if(XGrabPointer(c->display, RootWindow(c->display, c->phys_screen), False, MOUSEMASK, GrabModeAsync, GrabModeAsync, if(XGrabPointer(c->display,
RootWindow(c->display, c->phys_screen),
False, MOUSEMASK, GrabModeAsync, GrabModeAsync,
None, globalconf.cursor[CurMove], CurrentTime) != GrabSuccess) None, globalconf.cursor[CurMove], CurrentTime) != GrabSuccess)
return; return;
XQueryPointer(c->display, RootWindow(c->display, c->phys_screen), &dummy, &dummy, &x1, &y1, &di, &di, &dui); XQueryPointer(c->display,
RootWindow(c->display, c->phys_screen),
&dummy, &dummy, &x1, &y1, &di, &di, &dui);
for(;;) for(;;)
{ {
XMaskEvent(c->display, MOUSEMASK | ExposureMask | SubstructureRedirectMask, &ev); XMaskEvent(c->display, MOUSEMASK | ExposureMask | SubstructureRedirectMask, &ev);
@ -93,6 +104,11 @@ uicb_client_movemouse(int screen, char *arg __attribute__ ((unused)))
} }
} }
/** Resize client with mouse
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_client_resizemouse(int screen, char *arg __attribute__ ((unused))) uicb_client_resizemouse(int screen, char *arg __attribute__ ((unused)))
{ {

View File

@ -185,6 +185,11 @@ statusbar_get_position_from_str(const char * pos)
return BarTop; return BarTop;
} }
/** Toggle statusbar
* \param screen Screen ID
* \param arg Unused
* \ingroup ui_callback
*/
void void
uicb_statusbar_toggle(int screen, char *arg __attribute__ ((unused))) uicb_statusbar_toggle(int screen, char *arg __attribute__ ((unused)))
{ {
@ -196,13 +201,20 @@ uicb_statusbar_toggle(int screen, char *arg __attribute__ ((unused)))
arrange(screen); arrange(screen);
} }
/** Set statusbar position
* \param screen Screen ID
* \param arg off | bottom | right | left | top
* \ingroup ui_callback
*/
void void
uicb_statusbar_set_position(int screen, char *arg) uicb_statusbar_set_position(int screen, char *arg)
{ {
globalconf.screens[screen].statusbar->dposition = globalconf.screens[screen].statusbar->dposition =
globalconf.screens[screen].statusbar->position = globalconf.screens[screen].statusbar->position =
statusbar_get_position_from_str(arg); statusbar_get_position_from_str(arg);
statusbar_update_position(globalconf.display, globalconf.screens[screen].statusbar, &globalconf.screens[screen].padding); statusbar_update_position(globalconf.display,
globalconf.screens[screen].statusbar,
&globalconf.screens[screen].padding);
} }
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80 // vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80

View File

@ -77,6 +77,11 @@ common_new(Widget *widget, Statusbar *statusbar, cfg_t* config)
} }
/** Send command to widget
* \param screen Screen ID
* \param arg Widget command. Syntax depends on specific widget.
* \ingroup ui_callback
*/
void void
uicb_widget_tell(int screen, char *arg) uicb_widget_tell(int screen, char *arg)
{ {

10
xutil.c
View File

@ -29,6 +29,11 @@
extern awesome_config globalconf; extern awesome_config globalconf;
/** Execute another process, replacing the current instance of Awesome
* \param screen Screen ID
* \param arg Command
* \ingroup ui_callback
*/
void void
uicb_exec(int screen __attribute__ ((unused)), char *arg) uicb_exec(int screen __attribute__ ((unused)), char *arg)
{ {
@ -40,6 +45,11 @@ uicb_exec(int screen __attribute__ ((unused)), char *arg)
execlp(path, arg, NULL); execlp(path, arg, NULL);
} }
/** Spawn another process
* \param screen Screen ID
* \param arg Command
* \ingroup ui_callback
*/
void void
uicb_spawn(int screen, char *arg) uicb_spawn(int screen, char *arg)
{ {