~cairo-dock-team/ubuntu/precise/cairo-dock-plug-ins/3.0.0.0rc1

« back to all changes in this revision

Viewing changes to alsaMixer/src/applet-mixer.c

  • Committer: Bazaar Package Importer
  • Author(s): Julien Lavergne, Matthieu Baerts (matttbe), Julien Lavergne
  • Date: 2009-10-05 19:27:17 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20091005192717-mvqvb395guktr401
Tags: 2.0.9-0ubuntu1
[ Matthieu Baerts (matttbe) ]
* New upstream release (LP: #435590)
* debian/control: 
 - Remove ${shlibs:Depends} for integration plug-ins to avoid
   pulling shared libraries which are detected automatically.
 - Added curl as depends for cairo-dock-plug-ins
* debian/rules:
 - Add --enable-dnd2share and --enable-musicplayer to enable new applets.
 - Remove --enable-rhythmbox and --enable-nvidia to remove those applets,
   not maintained upstream.
* Update *.install to take all generated applets.

[ Julien Lavergne ]
* Adjust changelog with Daniel Holbach suggestions.
* cairo-dock-plug-ins.changelogs:  Install specific changelog for 2.0.9
* Build-depends on cairo-dock-dev (>= 2.0.9)

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
* along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
18
*/
19
19
 
20
 
/******************************************************************************
21
 
 
22
 
This file is a part of the cairo-dock program, 
23
 
released under the terms of the GNU General Public License.
24
 
 
25
 
Written by Fabrice Rey (for any bug report, please mail me to fabounet@users.berlios.de)
26
 
 
27
 
******************************************************************************/
28
 
 
29
20
#include <stdlib.h>
30
21
#include <math.h>
31
22
#include <string.h>
182
173
        
183
174
        int iMeanVolume = (iVolumeLeft + iVolumeRight) / (bHasLeft + bHasRight);
184
175
        
185
 
        g_print ("myData.iVolumeMin : %d ; myData.iVolumeMax : %d ; iMeanVolume : %d\n", myData.iVolumeMin, myData.iVolumeMax, iMeanVolume);
 
176
        cd_debug ("myData.iVolumeMin : %d ; myData.iVolumeMax : %d ; iMeanVolume : %d", myData.iVolumeMin, myData.iVolumeMax, iMeanVolume);
186
177
        return (100. * (iMeanVolume - myData.iVolumeMin) / (myData.iVolumeMax - myData.iVolumeMin));
187
178
}
188
179
 
271
262
        myData.pDialog = NULL;
272
263
        return FALSE;
273
264
}
274
 
 
 
265
static gboolean _on_key_press_dialog (int iClickedButton, GtkWidget *pInteractiveWidget, gpointer *data, CairoDialog *pDialog)
 
266
{
 
267
        myData.pDialog = NULL;  // le dialogue est dereference donc tout ce qu'on a a faire c'est prendre en compte ce fait !
 
268
}
275
269
void mixer_show_hide_dialog (void)
276
270
{
277
271
        if (myDesklet)
292
286
                memset (&attr, 0, sizeof (CairoDialogAttribute));
293
287
                attr.cText = cMessage;
294
288
                attr.pInteractiveWidget = pScale;
 
289
                attr.pActionFunc = (CairoDockActionOnAnswerFunc) _on_key_press_dialog;
295
290
                myData.pDialog = cairo_dock_build_dialog (&attr, myIcon, myContainer);
296
 
                g_signal_connect (G_OBJECT (myData.pDialog->pWidget),
 
291
                g_signal_connect (G_OBJECT (myData.pDialog->container.pWidget),
297
292
                        "button-press-event",
298
293
                        G_CALLBACK (on_button_press_dialog),
299
294
                        myData.pDialog);