From 7ba8bcb2b61432da59aa0639c63258d211edcd44 Mon Sep 17 00:00:00 2001 From: Mitchell Livingston Date: Sun, 20 Feb 2011 04:23:09 +0000 Subject: [PATCH] make sure filter buttons' tooltips are updated when the bar is shown --- macosx/Controller.m | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/macosx/Controller.m b/macosx/Controller.m index d78fc691f..2c7083f7e 100644 --- a/macosx/Controller.m +++ b/macosx/Controller.m @@ -2064,7 +2064,8 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy } //set button tooltips - [fFilterBar setCountAll: [fTorrents count] active: active downloading: downloading seeding: seeding paused: paused]; + if (fFilterBar) + [fFilterBar setCountAll: [fTorrents count] active: active downloading: downloading seeding: seeding paused: paused]; //clear display cache for not-shown torrents [previousTorrents removeObjectsInArray: allTorrents]; @@ -2899,8 +2900,9 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy { [[NSUserDefaults standardUserDefaults] setObject: FILTER_NONE forKey: @"Filter"]; [[NSUserDefaults standardUserDefaults] setInteger: GROUP_FILTER_ALL_TAG forKey: @"FilterGroup"]; - [self applyFilter]; } + + [self applyFilter]; //do even if showing to ensure tooltips are updated } //doesn't save shown state