mirror of
https://github.com/transmission/transmission.git
synced 2026-02-15 07:26:49 +00:00
* Set filter to "All" when hiding the filter bar Otherwise the filters will reset but the tab, for example "Downloading" will still be selected when the filter is shown again. We want to keep the tabs synchronized with filters state. * Remove unused BOOL parameter (the method is always called with YES) --------- Co-authored-by: beyondcompute <beyondcompute@users.noreply.github.com>
46 lines
1.4 KiB
Objective-C
46 lines
1.4 KiB
Objective-C
// This file Copyright © Transmission authors and contributors.
|
|
// It may be used under the MIT (SPDX: MIT) license.
|
|
// License text can be found in the licenses/ folder.
|
|
|
|
#import <AppKit/AppKit.h>
|
|
|
|
typedef NSString* FilterType NS_TYPED_EXTENSIBLE_ENUM;
|
|
|
|
extern FilterType const FilterTypeNone;
|
|
extern FilterType const FilterTypeActive;
|
|
extern FilterType const FilterTypeDownload;
|
|
extern FilterType const FilterTypeSeed;
|
|
extern FilterType const FilterTypePause;
|
|
extern FilterType const FilterTypeError;
|
|
|
|
typedef NSString* FilterSearchType NS_TYPED_EXTENSIBLE_ENUM;
|
|
|
|
extern FilterSearchType const FilterSearchTypeName;
|
|
extern FilterSearchType const FilterSearchTypeTracker;
|
|
|
|
extern NSInteger const kGroupFilterAllTag;
|
|
|
|
@interface FilterBarController : NSTitlebarAccessoryViewController<NSMenuItemValidation>
|
|
|
|
@property(nonatomic, readonly) NSArray<NSString*>* searchStrings;
|
|
|
|
- (instancetype)init;
|
|
|
|
- (IBAction)setFilter:(id)sender;
|
|
- (void)switchFilter:(BOOL)right;
|
|
- (IBAction)setSearchText:(id)sender;
|
|
- (IBAction)setSearchType:(id)sender;
|
|
- (IBAction)setGroupFilter:(id)sender;
|
|
- (void)reset;
|
|
- (void)focusSearchField;
|
|
- (BOOL)isFocused;
|
|
|
|
- (void)setCountAll:(NSUInteger)all
|
|
active:(NSUInteger)active
|
|
downloading:(NSUInteger)downloading
|
|
seeding:(NSUInteger)seeding
|
|
paused:(NSUInteger)paused
|
|
error:(NSUInteger)error;
|
|
|
|
@end
|