@@ -67,13 +67,10 @@ - (void)setup {
67
67
[self addSubview: _glassView];
68
68
69
69
containerView = _glassView.contentView ;
70
+ _showOnlyIcons = YES ;
70
71
} else {
71
72
self.backgroundView .backgroundColor = [UIColor colorWithWhite: 0 .12f alpha: 1 .0f ];
72
- }
73
- [self addSubview: self .backgroundView];
74
-
75
- if (@available (iOS 26.0 , *)) {
76
- _showOnlyIcons = YES ;
73
+ [self addSubview: self .backgroundView];
77
74
}
78
75
79
76
// On iOS 9 and up, we can use the new layout features to determine whether we're in an 'Arabic' style language mode
@@ -322,8 +319,9 @@ - (void)layoutToolbarButtons:(NSArray<UIButton *> *)buttons withSameButtonSize:(
322
319
const CGFloat buttonSize = 44 .0f ;
323
320
324
321
if (@available (iOS 26.0 , *)) {
322
+ CGFloat glassPadding = 4 .0f ;
325
323
CGFloat minPadding = 8 .0f ;
326
- CGFloat maxExtent = buttons.count * buttonSize + (minPadding * (buttons.count - 1 ));
324
+ CGFloat maxExtent = buttons.count * buttonSize + (minPadding * (buttons.count - 1 )) + (glassPadding * 2 . 0f ) ;
327
325
328
326
CGRect glassFrame = CGRectZero;
329
327
glassFrame.size .width = horizontally ? MIN (containerRect.size .width - (minPadding * 2 .0f ), maxExtent) : buttonSize;
@@ -332,7 +330,7 @@ - (void)layoutToolbarButtons:(NSArray<UIButton *> *)buttons withSameButtonSize:(
332
330
glassFrame.origin .y = horizontally ? 0 .0f : CGRectGetMidY (containerRect) - (glassFrame.size .height / 2 .0f );
333
331
_glassView.frame = glassFrame;
334
332
335
- CGFloat position = 0 . 0f ;
333
+ CGFloat position = glassPadding ;
336
334
for (UIButton *button in buttons) {
337
335
CGRect buttonFrame = CGRectMake (0.0 , 0.0 , buttonSize, buttonSize);
338
336
if (horizontally) {
0 commit comments