File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -154,7 +154,7 @@ const styles = StyleSheet.create({
154
154
// The picker will conform to whatever width is given, but we do
155
155
// have to set the component's height explicitly on the
156
156
// surrounding view to ensure it gets rendered.
157
- height : 20 ,
157
+ height : 24 ,
158
158
} ,
159
159
} ) ;
160
160
Original file line number Diff line number Diff line change @@ -20,15 +20,15 @@ - (instancetype)initWithFrame:(CGRect)frame
20
20
{
21
21
if ((self = [super initWithFrame: frame pullsDown: false ])) {
22
22
_color = [NSColor blackColor ];
23
- _customFont = [NSFont systemFontOfSize: 14 ];
23
+ _customFont = [NSFont systemFontOfSize: 14 ];
24
24
_selectedIndex = NSNotFound ;
25
- _textAlign = NSTextAlignmentCenter;
25
+ _textAlign = NSTextAlignmentCenter;
26
+
26
27
[self selectItemAtIndex: 0 ];
27
28
[[self menu ] setFont: _customFont];
28
29
self.pullsDown = false ;
29
30
[self setAction: @selector (mySelector: )];
30
31
[self setTarget: self ];
31
-
32
32
}
33
33
return self;
34
34
}
@@ -54,8 +54,8 @@ - (void)setItems:(NSArray<NSDictionary *> *)items
54
54
[row setAttributedTitle: as];
55
55
index++;
56
56
}
57
- [self setNeedsLayout: true ];
58
57
58
+ [self setNeedsLayout: true ];
59
59
}
60
60
61
61
@@ -64,7 +64,7 @@ - (void)setSelectedIndex:(NSInteger)selectedIndex
64
64
if (_selectedIndex != selectedIndex) {
65
65
_selectedIndex = selectedIndex;
66
66
dispatch_async (dispatch_get_main_queue (), ^{
67
- [self setSelectedIndex : selectedIndex];
67
+ [self selectItemAtIndex : selectedIndex];
68
68
});
69
69
}
70
70
}
You can’t perform that action at this time.
0 commit comments