Changeset 11267


Ignore:
Timestamp:
Sep 27, 2010, 8:24:41 PM (11 years ago)
Author:
charles
Message:

(trunk gtk) #3585 -- in torrent_cell_renderer_get_size(), set x_offset and y_offset even if cell_area is NULL

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gtk/torrent-cell-renderer.c

    r11135 r11267  
    521521            *height = h;
    522522
    523         if( cell_area ) {
    524             if( x_offset ) *x_offset = 0;
    525             if( y_offset ) {
    526                 *y_offset = 0.5 * ( cell_area->height - ( h + ( 2 * cell->ypad ) ) );
    527                 *y_offset = MAX( *y_offset, 0 );
    528             }
    529         }
     523        if( x_offset )
     524            *x_offset = cell_area ? cell_area->x : 0;
     525         
     526        if( y_offset )
     527            *x_offset = cell_area ? (int)((cell_area->height - (cell->ypad*2 +h)) / 2.0) : 0;
    530528    }
    531529}
Note: See TracChangeset for help on using the changeset viewer.