~cairo-dock-team/ubuntu/oneiric/cairo-dock-plug-ins/2.3.0-2.1

« back to all changes in this revision

Viewing changes to switcher/src/applet-notifications.c

  • Committer: Bazaar Package Importer
  • Author(s): Matthieu Baerts (matttbe)
  • Date: 2010-05-07 22:46:35 UTC
  • Revision ID: james.westby@ubuntu.com-20100507224635-3iqm9p2xq15gwwr7
Tags: 2.1.3-10-lucid-0ubuntu3
* New bug-fixed release (LP: #576647)
* LP: #575178 (MP: fixed a double-free on the "cover-dir" variable
             of the banshee backend)
* LP: #523447 (MP: fixed a memory buffer overflow when getting the
             cover if the artist or album has chinese/russian characters)
* CD Forum: Switcher : fixed a division by 0 in the case he number
  of desktop is null (can occur if the dock is launched before the WM)
* CD Forum: Mail : allow the dock to isolate the applet if it crashes

Show diffs side-by-side

added added

removed removed

Lines of Context:
268
268
static gboolean _cd_switcher_redraw_main_icon_idle (CairoDockModuleInstance *myApplet)
269
269
{
270
270
        CD_APPLET_ENTER;
271
 
        cd_switcher_draw_main_icon ();
 
271
        if (myData.switcher.iNbColumns == 0)
 
272
        {
 
273
                cd_switcher_compute_nb_lines_and_columns ();
 
274
                cd_switcher_get_current_desktop ();
 
275
        }
 
276
        cd_switcher_draw_main_icon ();
272
277
        myData.iSidRedrawMainIconIdle = 0;
273
278
        CD_APPLET_LEAVE (FALSE);
274
279
        //return FALSE;
458
463
                glPushMatrix ();
459
464
                if (myDesklet)
460
465
                        glTranslatef (-myDesklet->container.iWidth/2, -myDesklet->container.iHeight/2, -myDesklet->container.iHeight*(sqrt(3)/2));
461
 
                glTranslatef (x, y, 0);
 
466
                        glTranslatef (x - ((myIcon->iTextWidth & 1) ? 0.5 : 0.),
 
467
                                y - ((myIcon->iTextHeight & 1) ? 0.5 : 0.),
 
468
                                0);
462
469
                cairo_dock_draw_texture_with_alpha (myIcon->iLabelTexture, myIcon->iTextWidth, myIcon->iTextHeight, myData.fDesktopNameAlpha);
463
470
                glPopMatrix ();
464
471
        }