summaryrefslogtreecommitdiff
path: root/src/interface.c
AgeCommit message (Collapse)AuthorFilesLines
2011-12-18interface: Use printf precision and padding for volume bar printingBenjamin Franzke1-14/+25
2011-12-18interface: getmaxx is not standard, use getmaxyx insteadBenjamin Franzke1-2/+3
2011-12-18interface: Stop keeping track of cursor position ourselfBenjamin Franzke1-20/+20
2011-12-18interface: Unify drawing code for sinks and inputsBenjamin Franzke1-72/+39
They are drawn from the same function that calls itself recursiveley for childs of the currently drawn volume control. So its called for all sink_inputs that belong to a sink.
2011-12-18interface: Dont postfix spaces, always prefixBenjamin Franzke1-4/+4
This'll make it possible to have proper displaying when clamping ctx::max_name_len in future.
2011-12-18interface: print_volume can use vol_ctl parameter nowBenjamin Franzke1-5/+5
2011-12-18set_max_name_len: Simplify code to two calls to one helper functionBenjamin Franzke1-17/+18
2011-12-18Finally move interface_get_current_ctl into interface.cBenjamin Franzke1-0/+44
2011-12-18Rename vol_ctl_object to vol_ctlBenjamin Franzke1-1/+1
2011-12-18Unify common sink(_input) properties to a base objectBenjamin Franzke1-11/+10
2011-12-14Increase warning leaves, and fix new occured onesBenjamin Franzke1-2/+3
2011-12-13Let interface_set_status use va argsBenjamin Franzke1-2/+7
2011-12-13Add goto based error-path cleanup to mainBenjamin Franzke1-3/+5
2011-12-13Allow to quit with a non-ready contextBenjamin Franzke1-3/+0
2011-12-13Fix some leaksBenjamin Franzke1-1/+9
2011-12-13interface: Rename print_sink_list to interface_redrawBenjamin Franzke1-2/+3
2011-12-13Add a list_foreach makro for GListBenjamin Franzke1-16/+11
Saves around 1-2 lines per foreach, and should be more error prone.
2011-12-13config: Read keymap from configuration fileBenjamin Franzke1-189/+6
This needed a split of the switch that handled input before into several small callback functions.
2011-12-13sink: Remove struct typedefsBenjamin Franzke1-16/+16
2011-12-13Add config property to select display name to useBenjamin Franzke1-3/+2
2011-12-05interface: Fix unitialized variableBenjamin Franzke1-1/+1
2011-10-22interface: Derive new chooser_input directly when movingBenjamin Franzke1-26/+16
Dont schedule this until redraw, since this needed hacks to ensure we got the update.
2011-10-22interface: Dont move a sink_input if there is only one sinkBenjamin Franzke1-1/+4
2011-10-22Add License header to source filesBenjamin Franzke1-0/+19
2011-10-22Fix 80 column widthBenjamin Franzke1-28/+53
2011-10-21Fix selection when moving an input aroundBenjamin Franzke1-0/+1
We may not get the update for the moved index immediately, but we calculate the new position for the selection on redraw. So schedule redraw until we get the update, when we move around.
2011-10-21interface: Calculate offsets less oftenBenjamin Franzke1-17/+15
2011-10-21Store all input_infos in one big listBenjamin Franzke1-19/+55
This makes the lookup routines independent of each other, which allows gradual updates later.
2011-10-21Fix ident mistakes introduces by previous mass changesBenjamin Franzke1-118/+113
Variables were substituted by sed, so indentation got messed up.
2011-10-21Stop using global variables.Benjamin Franzke1-132/+114
Rather store it in a context, thats used everywhere as parameter, or as userdata.
2011-10-21interface: Stop the use of ugly tmp structuresBenjamin Franzke1-40/+28
2011-10-21Use a GList instead of GArray for sinks.Benjamin Franzke1-40/+50
This lets us drop our ugly GArray wrappers sink.c and sink_input.c. It will make gradual updates of sinks easier, since elements can be added and dropped everywhere in the list easily.
2011-10-21interface: Cache some boolean expressionsBenjamin Franzke1-4/+8
2011-10-21signalfd: Read out received signalsBenjamin Franzke1-0/+11
2011-10-20Use signalfd if availableBenjamin Franzke1-0/+32
If kqueue can be added as well, our homegrown kinda ugly signal dispatcher could be killed.
2011-10-20g_unix_signal: Remove g_ prefix to not collide with glibBenjamin Franzke1-2/+2
There is a g_unix_signal_new function in glib as well now, but that is only allowed to be used for SIGINT, SIGHUP and SIGTERM, so we have to stay with our own.
2011-10-20Kill off g_curses_inputBenjamin Franzke1-5/+11
Use a g_io_channel that listens to STDIN_FILENO instead.
2011-10-19interface_set_status: Rename "save" to "status"Benjamin Franzke1-5/+6
2011-10-19interface: Add defines for special chooser_input statesBenjamin Franzke1-13/+16
2011-10-19interface: Rename status to interface_set_statusBenjamin Franzke1-2/+2
2011-10-19interface.h: Remove private function prototypesBenjamin Franzke1-100/+99
Therefore reorder function definitions in interface.c.
2011-10-19Coding style: Seperate line for function return typeBenjamin Franzke1-9/+18
2011-10-19interface: Rename get_input to interface_get_inputBenjamin Franzke1-2/+3
2011-02-08Fix: output formatingyounix1-2/+3
- max_name_len(): add indentation space - add space between volume bar and border
2011-02-08Dynamic growing volume bar.younix1-4/+5
Get the current window width and calculate the volume bar width.
2011-02-08Printing full name length.younix1-7/+47
Adding function to find out the longest name of all SINK's and INPUT's. Inserting indentations in amount of this max. length.
2010-11-04Merge branch 'master' of gitorious.org:pa-sink-ctl/pa-sink-ctlyounix1-0/+4
2010-11-04add commentyounix1-3/+3
2010-11-04get_input: only handle inputs, when context is readyBenjamin Franzke1-0/+4
2010-10-21status: fix pointer to be constben1-1/+1