Skip to content

Commit 10481fe

Browse files
committed
Fixes
1 parent a0282e8 commit 10481fe

File tree

4 files changed

+22
-58
lines changed

4 files changed

+22
-58
lines changed

ApplicationLibrary/Views/Connections/ConnectionListView.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,9 @@ public struct ConnectionListView: View {
6161
}
6262
}
6363
}
64+
#if os(macOS)
6465
.searchable(text: $searchText)
66+
#endif
6567
.alertBinding($alert)
6668
.onAppear {
6769
connect()

ApplicationLibrary/Views/Dashboard/ActiveDashboardView.swift

Lines changed: 15 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -50,23 +50,25 @@ public struct ActiveDashboardView: View {
5050
VStack {
5151
#if os(iOS) || os(tvOS)
5252
if ApplicationLibrary.inPreview || profile.status.isConnectedStrict {
53-
viewBuilder {
54-
#if os(iOS)
55-
if #available(iOS 16.0, *) {
56-
content1
57-
} else {
58-
content0
59-
}
60-
#else
61-
content0
62-
#endif
53+
Picker("Page", selection: $selection) {
54+
ForEach(DashboardPage.allCases) { page in
55+
page.label
56+
}
6357
}
58+
.pickerStyle(.segmented)
6459
#if os(iOS)
65-
.navigationBarTitleDisplayMode(.inline)
60+
.padding([.leading, .trailing])
61+
.navigationBarTitleDisplayMode(.inline)
6662
#endif
67-
.onAppear {
68-
UIScrollView.appearance().isScrollEnabled = false
63+
TabView(selection: $selection) {
64+
ForEach(DashboardPage.enabledCases) { page in
65+
page.contentView($profileList, $selectedProfileID, $systemProxyAvailable, $systemProxyEnabled)
66+
.tag(page)
67+
}
6968
}
69+
#if os(iOS)
70+
.navigationBarTitleDisplayMode(.inline)
71+
#endif
7072
.tabViewStyle(.page(indexDisplayMode: .never))
7173
} else {
7274
OverviewView($profileList, $selectedProfileID, $systemProxyAvailable, $systemProxyEnabled)
@@ -91,46 +93,6 @@ public struct ActiveDashboardView: View {
9193
.alertBinding($alert)
9294
}
9395

94-
@ViewBuilder
95-
private var content0: some View {
96-
Picker("Page", selection: $selection) {
97-
ForEach(DashboardPage.allCases) { page in
98-
page.label
99-
}
100-
}
101-
.pickerStyle(.segmented)
102-
#if os(iOS)
103-
.padding([.leading, .trailing])
104-
.navigationBarTitleDisplayMode(.inline)
105-
#endif
106-
TabView(selection: $selection) {
107-
ForEach(DashboardPage.enabledCases) { page in
108-
page.contentView($profileList, $selectedProfileID, $systemProxyAvailable, $systemProxyEnabled)
109-
.tag(page)
110-
}
111-
}
112-
}
113-
114-
@available(iOS 16.0, *)
115-
@ViewBuilder
116-
private var content1: some View {
117-
TabView(selection: $selection) {
118-
ForEach(DashboardPage.enabledCases) { page in
119-
page.contentView($profileList, $selectedProfileID, $systemProxyAvailable, $systemProxyEnabled)
120-
.tag(page)
121-
}
122-
}
123-
.toolbar {
124-
ToolbarTitleMenu {
125-
Picker("Page", selection: $selection) {
126-
ForEach(DashboardPage.allCases) { page in
127-
page.label
128-
}
129-
}
130-
}
131-
}
132-
}
133-
13496
private func doReload() async {
13597
defer {
13698
isLoading = false

ApplicationLibrary/Views/Dashboard/DashboardPage.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ public enum DashboardPage: Int, CaseIterable, Identifiable {
1313
}
1414

1515
public extension DashboardPage {
16-
#if !os(tvOS)
16+
#if !tvOS
1717
static var enabledCases: [DashboardPage] = [
1818
.overview,
1919
.groups,

sing-box.xcodeproj/project.pbxproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2734,7 +2734,7 @@
27342734
"@executable_path/../../../../Frameworks",
27352735
);
27362736
MACOSX_DEPLOYMENT_TARGET = 13.0;
2737-
MARKETING_VERSION = 1.9.4;
2737+
MARKETING_VERSION = "1.10.0-alpha.18";
27382738
PRODUCT_BUNDLE_IDENTIFIER = io.nekohasekai.sfavt.system;
27392739
PRODUCT_NAME = "$(inherited)";
27402740
PROVISIONING_PROFILE_SPECIFIER = "";
@@ -2770,7 +2770,7 @@
27702770
"@executable_path/../../../../Frameworks",
27712771
);
27722772
MACOSX_DEPLOYMENT_TARGET = 13.0;
2773-
MARKETING_VERSION = 1.9.4;
2773+
MARKETING_VERSION = "1.10.0-alpha.18";
27742774
PRODUCT_BUNDLE_IDENTIFIER = io.nekohasekai.sfavt.system;
27752775
PRODUCT_NAME = "$(inherited)";
27762776
PROVISIONING_PROFILE_SPECIFIER = "";
@@ -2812,7 +2812,7 @@
28122812
"@executable_path/../Frameworks",
28132813
);
28142814
MACOSX_DEPLOYMENT_TARGET = 13.0;
2815-
MARKETING_VERSION = 1.9.4;
2815+
MARKETING_VERSION = "1.10.0-alpha.18";
28162816
PRODUCT_BUNDLE_IDENTIFIER = io.nekohasekai.sfavt.standalone;
28172817
PRODUCT_NAME = SFM;
28182818
PROVISIONING_PROFILE_SPECIFIER = "";
@@ -2853,7 +2853,7 @@
28532853
"@executable_path/../Frameworks",
28542854
);
28552855
MACOSX_DEPLOYMENT_TARGET = 13.0;
2856-
MARKETING_VERSION = 1.9.4;
2856+
MARKETING_VERSION = "1.10.0-alpha.18";
28572857
PRODUCT_BUNDLE_IDENTIFIER = io.nekohasekai.sfavt.standalone;
28582858
PRODUCT_NAME = SFM;
28592859
PROVISIONING_PROFILE_SPECIFIER = "";

0 commit comments

Comments
 (0)