From 1702f37d3ec5627feed81347ffeb8cf432e9857e Mon Sep 17 00:00:00 2001 From: TrueZhuanjia Date: Sun, 22 Jun 2025 11:11:52 +0800 Subject: [PATCH] - localization fixes - auto hide all hidden menusections --- Limelight/Localization/Localizable.xcstrings | 25 +++++++++++++++++++- Limelight/MenuSectionView.m | 7 ++++++ 2 files changed, 31 insertions(+), 1 deletion(-) diff --git a/Limelight/Localization/Localizable.xcstrings b/Limelight/Localization/Localizable.xcstrings index b9cdf0f9..09a518fd 100644 --- a/Limelight/Localization/Localizable.xcstrings +++ b/Limelight/Localization/Localizable.xcstrings @@ -168,7 +168,7 @@ } } }, - "[ Open On-Screen Widget Tool ]" : { + "[ Open on-screen widget tool ]" : { "extractionState" : "manual", "localizations" : { "zh-Hans" : { @@ -191,6 +191,29 @@ } } }, + "[ Switch among on-screen widget profiles ]" : { + "extractionState" : "manual", + "localizations" : { + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "[ 切换屏显控件布局 ]" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "[ 切换屏显控件布局 ]" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "[ 切换屏显控件布局 ]" + } + } + } + }, "%@ is currently running" : { "extractionState" : "manual", "localizations" : { diff --git a/Limelight/MenuSectionView.m b/Limelight/MenuSectionView.m index c5ceb039..c44f379c 100644 --- a/Limelight/MenuSectionView.m +++ b/Limelight/MenuSectionView.m @@ -321,6 +321,13 @@ - (void)updateViewForFoldState { [self setupConstraints]; + NSInteger visibleCount = 0; + for (UIView *subview in _rootStackView.arrangedSubviews) { + if (!subview.isHidden) { + visibleCount++; + } + } + self.hidden = visibleCount == 0; if (_expanded) { _rootStackView.hidden = NO; _separatorLine.hidden = NO;