Commit Graph

9 Commits

Author SHA1 Message Date
Stefano Mazzucco 948d98be90 Prevent volume notifications from stacking
Feature requested originally by p-conrad in
https://github.com/stefano-m/awesome-pulseaudio_widget/pull/4
2018-12-02 21:43:15 +00:00
Stefano Mazzucco fb8a6f4e5c Bump dependencies and conform to latest dbus_proxy API
Modify the callbacks used by connect_signal to take the actual argument from
the signal rather than an array containing the arguments. This breaking change
was introduced by dbus_proxy 0.9.0.
2017-11-11 17:59:57 +00:00
Stefano Mazzucco 3410f9ac7a Unify code from widget and widget_client files
It turns out that Awesome can automatically deal with GLib's main loop and we
don't need an external process to listen to pulseaudio's DBus. This greatly
simplifies the code since we:

- can merge the widget and widget_client files
- don't need to do all the string parsing but can modify the widget directly

Credit to https://github.com/psychon for raising the issue and providing sample
code.

Closes #1 (https://github.com/stefano-m/awesome-pulseaudio_widget/issues/1)
2017-07-10 22:27:33 +01:00
Stefano Mazzucco 8a357e481f Add support for sources (i.e. microphones)
The widget will to its best to detect the active source.

- Updated client code to detect source changes and add object path information to
  the volume and mute updated signals.
- Added new functions to toggle mute and change volume on the microphone. The
  functions name have `_mic` appended.
- Refactored widget code to reduce duplication.
- Updated README with examples on how to add controls for the microphone to `rc.lua`.
2017-06-02 12:12:42 +01:00
Stefano Mazzucco a80a9a39b6 Rename get_sink to get_device as per latest pulseaudio_dbus changes 2017-06-02 10:28:51 +01:00
Stefano Mazzucco 8916e9a973 Honor muted state on initialization and sink change 2017-05-25 22:07:53 +01:00
Stefano Mazzucco 5d9df5db5f Add dynamic volume/sink updates: use dbus_proxy and Awesome 4.x
- use Awesome 4.x API. This widget will not work with earlier versions.
- use the latest pulseaudio_dbus (v0.10.0) backed by dbus_proxy.
- use client script to listen to signals from pulseaudio to update the widget
  status.
- update copyright notice
- refactor widget code
- update the documentation
- add rockspec for development
- add rockspec for version 0.2.0
2017-05-25 14:41:27 +01:00
Stefano Mazzucco dc52f1c58b Do not break stuff if pulseaudio is not available
Wrap pulse.get_address with pcall and notify Awesome if an error
occurred instead of breaking everything.
2016-09-17 23:37:14 +01:00
Stefano Mazzucco 2a287cdd20 Initial commit and first public release: 0.1.0 2016-08-14 20:08:49 +01:00