Commit Graph

371 Commits

Author SHA1 Message Date
Marcel Hollerbach 9745890a37 Revert "Revert "mixer: do not set back the value from emix once the drag is finished""
This reverts commit fba185798c.

There is not even a description why you reverted it. This is a bugfix
that fixed a bug. So talk to me what the issue is, but please stop
reverting commits silently.
2017-02-23 09:08:24 +01:00
Michael Bouchaud cb6ea9f747 e_client_volume: check volume setted after a slider drag 2017-02-23 00:36:17 +01:00
Michaël Bouchaud (yoz) fba185798c Revert "mixer: do not set back the value from emix once the drag is finished"
This reverts commit 8724313b8e.
2017-02-22 22:59:13 +01:00
Michaël Bouchaud (yoz) dbdf411b48 mixer: use VOLSET macro in volume output set 2017-02-22 22:59:13 +01:00
Carsten Haitzler 35bb87529f e mixer module - run pulseaudio if connect fails
so i have a situatioon where pulse is not started automagically. if
e's mixer it set to pulse... then stick to it, run pulse and keep
trying to connect every 0.2 sec until connection works. this makes
sound "just work" tm as it should...

@fix
2017-02-20 22:58:59 +09:00
Michael Bouchaud 9320b0e4ea e_client_volume: forget to remove the separator 2017-02-20 01:48:40 +01:00
Michael Bouchaud 51a5ec4e6a e_client_volume: display a control per stream in the popup volume
This commit enhance the e_client_volume popup. Now you could see which sink
belongs to an e_client and allow you to control it. Sadly I haven't added a
scroller to this popup, I will add it later. Lots of calcs is needed to
display it correctly.
2017-02-20 02:23:16 +01:00
Michael Bouchaud 0a73905895 e_client_volume: add E_EVENT_CLIENT_VOLUME_SINK handler
This commit introduce 3 new handlers to e_client_volume API. These allow to
catch event about sink add, del and update
2017-02-20 02:21:14 +01:00
Michael Bouchaud 939ac0b93d e_client_volume: add sink_name_get API to e_client_volume 2017-02-20 00:46:59 +01:00
Carsten Haitzler 26b68f8c7e e mixer pulse backened -f ix warning about use of uninit var
display really isn't uninitialized due to the logic, but compielr is
kind of right in theory... but less warnings is better so we fix the
real problems more easily. fix.
2017-02-12 16:25:35 +09:00
Derek Foreman 4cf555f36e Replace all timer_reset with timer_loop_reset
Another sed bomb - didn't occur to me first time around to
check for this.  Cleans up more clock_gettime calls.
2017-02-06 15:59:25 -06:00
Derek Foreman 73aecd73ab Replace all timer_add with timer_loop_add
So yeah, I've literally used sed to replace every occurrence of
ecore_time_add() with ecore_timer_loop_add() because I'm reasonably
confident that no part of E has a legitimate need for timer based on the
exact current time.

It would be really nice if I'm not wrong. :)

The reason for this is the incredible spew of clock_gettime() calls I'm
seeing on an ARM system (that should have a vdso for gettime, but...)
This can amount to thousands of system calls per second.

 #YOLO
2017-02-03 15:52:28 -06:00
Mike Blumenkrantz 49d9cea5aa center menu-triggered volume popup on same zone as client 2016-11-07 11:26:46 -05:00
Michaël Bouchaud (yoz) be154b60c8 mixer: close the file descriptor on error.
CID: 1365407
2016-11-07 10:32:04 +01:00
Michaël Bouchaud (yoz) 568a676073 mixer: Don't sync volume sink with e_client if they have more than one.
If we got more than one volume sink in e_client and we change the volume
of one of them all sink of this e_client are updated to the same volume.
So don't update e_client volume if we got more than 1 sink.

T4821
2016-11-07 10:26:56 +01:00
Michaël Bouchaud (yoz) ec12cff9f4 mixer: fix a typo spotted by coverity
CID: 1365340
2016-11-07 10:19:28 +01:00
Michaël Bouchaud (yoz) 2a0b4dfbc4 mixer: fix coverity issues 2016-11-02 15:27:38 +01:00
Stefan Schmidt b13486599e mixer: remove unused variables 2016-10-31 11:34:31 +01:00
Stefan Schmidt f606935067 mixer: mark unused function parameter as such 2016-10-31 11:34:02 +01:00
Marcel Hollerbach 8724313b8e mixer: do not set back the value from emix once the drag is finished
emix can still have wrong values from pa, and thus the value will jump
back and later come back to the right pos:

Here a video of what is happening:
http://omicron.homeip.net/filedump/mixer_gadget_bug.ogv

Thank you morluxus!
2016-10-28 11:41:00 +02:00
Michaël Bouchaud (yoz) b2d67bd68a Revert "mixer: lock up the slider for the case a drag is in progress"
This reverts commit eed35d3c4f.

This is a bad workaround, I have fixed the issue so we don't need it
anymore.
2016-10-27 22:38:46 +02:00
Michaël Bouchaud (yoz) b65cb5df92 mixer: add volume control to e_client menu
Add a button to the window menu, when clicked this one make a new window to
control the volume of the app.

@features
2016-10-27 22:34:17 +02:00
Michaël Bouchaud (yoz) 307f0831ce mixer: use the new e_client api to export volume control by app.
We use the pulseaudio backend to export volume control by app.
This commit introduce 3 news shortcuts to control the volume with the current
focused window.

@features
2016-10-27 21:54:40 +02:00
Michaël Bouchaud (yoz) 1943cee080 mixer: fix the volume conversion calc into pulseaudio backend
a get and a set don't give the same result

@fix
2016-10-27 21:54:39 +02:00
Marcel Hollerbach 838dde02ee mixer: we changed that name when we merged the mixer in 2016-10-11 14:16:53 +02:00
Marcel Hollerbach eed35d3c4f mixer: lock up the slider for the case a drag is in progress
if you click on the slider in the gadget the slider jumps a back to the
old volume and then to the new volume, this is because a pulseaudio
update is sent while the last changed event was called, but not the
drag_stop callback.
2016-09-14 10:43:17 +02:00
Marcel Hollerbach 1a3086b2c2 mixer: introduce emix_max_volume_get
This lets the module decide what its maximum value is.
Everything over 100% is considered overloading. And is protected by the
mixer and the gadget.
2016-09-07 11:05:11 +02:00
Marcel Hollerbach 1da2bbcd9c mixer: introduce Barrier checks
in this barrier checks the module checks that the user is explicit going
over the value of 100%
2016-09-07 11:05:11 +02:00
Flavio Ceolin 5df7963ad1 emix: when in alsa mode only operate on master 2016-09-06 11:54:51 +02:00
Marcel Hollerbach 4f0e3bce84 emix: update sink of sink_input when changed
this fixes none changing sinks in the app.
2016-06-25 17:12:35 +02:00
Mike Blumenkrantz 366193f2d2 remove pulse sinks/sources from list before running cbs which access the list
this guarantees a crash any time the default sink gets removed since it will
always re-set the about-to-be-deleted default sink as the default sink

fix T3277 probably
2016-05-17 15:05:18 -04:00
Mike Blumenkrantz 01c261e9f7 unset DISPLAY during mixer's pulse backend startup
fixes more xwayland deadlocks
2016-05-06 13:40:03 -04:00
Mike Blumenkrantz ed25a5005f clean up mixer includes
config.h needs to be included. always.
2016-05-06 13:38:09 -04:00
Mike Blumenkrantz b64a637428 allow mixer volume increase actions to exceed 100%
ref 0bbb20a3be

cc @raster probably should have some kind of theme indicator in the theme
for "high" volumes > 100%
2016-04-18 11:44:52 -04:00
Mike Blumenkrantz fe34f45995 Revert "mixer: try to fix a possible bug"
This reverts commit 61182d6434.

accidentally pushed, does not resolve anything
2016-04-12 13:38:44 -04:00
Marcel Hollerbach 61182d6434 mixer: try to fix a possible bug
for the case the default sink was removed the gadget will get a new
  default sink again, for the case of pa there is the possibility that
  at this time the sink is still the default one, but the sink gets
  removed. so we better set the default index to -1 and return just some
  sink for the case the default is deleted.
2016-04-12 13:33:54 -04:00
Mike Blumenkrantz d1d30029d1 select mixer popup sink after popup has been fully initialized
attempting to select too early results in callbacks being triggered
before various widgets are available
2016-01-08 12:05:41 -05:00
Derek Foreman 1965c7965e emix: Rename parameter bool to mute
Summary: Broke my wayland build because something included stdbool.h

Reviewers: devilhorns, zmike

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3467
2015-12-18 16:42:30 -05:00
Marcel Hollerbach f174008a83 mixer: only save state if not in init
If we are calling emix_config_save_state_get while in init, we are
freeing the list emix_config_save_state_restore is iterating over.
This leads to crashes.

@fix T2942
@fix T2906
2015-12-18 13:21:08 +01:00
Marcel Hollerbach d9e01e851f alsa: fix a valgrind warning
Valgrind was warning about the values not initialized
2015-12-18 13:20:48 +01:00
Stefan Schmidt 7ed2381722 pulse backend: correct declaration of function with no parameters
We have to use void in a function declaration if we want no function
parameters. Using just empty parenthesis means the function takes an
unspecified number of parameters.

We had it correct for most declarations and this series fixes it for
the rest.

Thanks for the sparse semantic parser for pointing this out.
2015-11-26 18:10:47 +01:00
Carsten Haitzler e5f56f95e9 e mixer fix - fix default mixer to pulse if there
this makes e use the correct mixer backend if pulse is available as
opposed to using alsa going behind pulses back.

@fix
2015-11-14 10:14:30 +09:00
Mike Blumenkrantz 3ad521ab9c ensure that all mixer volumes resolve to the appropriate gadget icon
reported by Jef91 in #e
2015-11-11 11:54:58 -05:00
Flavio Ceolin a524d165bc modules:mixer: Avoid pa backend from crash
Check the pulseaudio's context error and if info is not null before
get server's information.
2015-10-24 19:10:40 -02:00
Amitesh Singh de740b2520 pulseaudio: pass big data as pass by reference
CID: 1308394
2015-10-14 21:51:00 +05:30
Marcel Hollerbach 2fd6f95a9b mixer: start app from bin directory
before the app was installed into the modules directory, now its
installed to the bin directory
2015-10-13 22:06:00 +02:00
Marcel Hollerbach 03888cf941 mixer: install icon and .desktop file 2015-10-13 22:06:00 +02:00
Carsten Haitzler 9c5b6acb05 e mixer - be more robust if pulse exits/crashes and def sink is null
ensure there are protections everywhere for when default sink is null
- mixer did crash when pulse crashed and a popup was to be shown...
2015-10-10 11:07:24 +09:00
Carsten Haitzler 530c8613c8 e mixer - shut up coverity CID 1323098 2015-09-09 11:02:23 +09:00
Carsten Haitzler 2a0b1c024b e mixer - save state when we get change events too
this plugs a gap where wrong state is saved.
2015-09-06 20:04:22 +09:00