mirror of
https://github.com/ichmagmaus111/ghostgram.git
synced 2026-08-23 14:22:30 +02:00
chore: migrate to new version + fixed several critical bugs
- Migrated project to latest Telegram iOS base (v12.3.2+) - Fixed circular dependency between GhostModeManager and MiscSettingsManager - Fixed multiple Bazel build configuration errors (select() default conditions) - Fixed duplicate type definitions in PeerInfoScreen - Fixed swiftmodule directory resolution in build scripts - Added Ghostgram Settings tab in main Settings menu with all 5 features - Cleared sensitive credentials from config.json (template-only now) - Excluded bazel-cache from version control
This commit is contained in:
+22
-18
@@ -142,7 +142,7 @@ private final class AuthorizationSequenceCountrySelectionNavigationContentNode:
|
||||
|
||||
self.cancel = cancel
|
||||
|
||||
self.searchBar = SearchBarNode(theme: SearchBarNodeTheme(theme: theme), strings: strings, fieldStyle: .modern)
|
||||
self.searchBar = SearchBarNode(theme: SearchBarNodeTheme(theme: theme), presentationTheme: theme, strings: strings, fieldStyle: .modern)
|
||||
let placeholderText = strings.Common_Search
|
||||
let searchBarFont = Font.regular(17.0)
|
||||
|
||||
@@ -169,10 +169,12 @@ private final class AuthorizationSequenceCountrySelectionNavigationContentNode:
|
||||
return 54.0
|
||||
}
|
||||
|
||||
override func updateLayout(size: CGSize, leftInset: CGFloat, rightInset: CGFloat, transition: ContainedViewLayoutTransition) {
|
||||
override func updateLayout(size: CGSize, leftInset: CGFloat, rightInset: CGFloat, transition: ContainedViewLayoutTransition) -> CGSize {
|
||||
let searchBarFrame = CGRect(origin: CGPoint(x: 0.0, y: size.height - self.nominalHeight), size: CGSize(width: size.width, height: 54.0))
|
||||
self.searchBar.frame = searchBarFrame
|
||||
self.searchBar.updateLayout(boundingSize: searchBarFrame.size, leftInset: leftInset, rightInset: rightInset, transition: transition)
|
||||
|
||||
return size
|
||||
}
|
||||
|
||||
func activate() {
|
||||
@@ -332,7 +334,7 @@ public final class AuthorizationSequenceCountrySelectionController: ViewControll
|
||||
self.displayCodes = displayCodes
|
||||
self.glass = glass
|
||||
|
||||
super.init(navigationBarPresentationData: NavigationBarPresentationData(theme: NavigationBarTheme(rootControllerTheme: theme, hideBackground: glass, hideSeparator: glass), strings: NavigationBarStrings(presentationStrings: strings)))
|
||||
super.init(navigationBarPresentationData: NavigationBarPresentationData(theme: NavigationBarTheme(rootControllerTheme: theme, hideBackground: glass, hideSeparator: glass, style: glass ? .glass : .legacy), strings: NavigationBarStrings(presentationStrings: strings)))
|
||||
|
||||
self._hasGlassStyle = glass
|
||||
|
||||
@@ -392,13 +394,13 @@ public final class AuthorizationSequenceCountrySelectionController: ViewControll
|
||||
id: "close",
|
||||
component: AnyComponent(GlassBarButtonComponent(
|
||||
size: barButtonSize,
|
||||
backgroundColor: self.theme.rootController.navigationBar.glassBarButtonBackgroundColor,
|
||||
backgroundColor: nil,
|
||||
isDark: self.theme.overallDarkAppearance,
|
||||
state: .generic,
|
||||
state: .glass,
|
||||
component: AnyComponentWithIdentity(id: "close", component: AnyComponent(
|
||||
BundleIconComponent(
|
||||
name: "Navigation/Close",
|
||||
tintColor: self.theme.rootController.navigationBar.glassBarButtonForegroundColor
|
||||
tintColor: self.theme.chat.inputPanel.panelControlColor
|
||||
)
|
||||
)),
|
||||
action: { [weak self] _ in
|
||||
@@ -413,13 +415,13 @@ public final class AuthorizationSequenceCountrySelectionController: ViewControll
|
||||
id: "search",
|
||||
component: AnyComponent(GlassBarButtonComponent(
|
||||
size: barButtonSize,
|
||||
backgroundColor: self.theme.rootController.navigationBar.glassBarButtonBackgroundColor,
|
||||
backgroundColor: nil,
|
||||
isDark: self.theme.overallDarkAppearance,
|
||||
state: .generic,
|
||||
state: .glass,
|
||||
component: AnyComponentWithIdentity(id: "search", component: AnyComponent(
|
||||
BundleIconComponent(
|
||||
name: "Navigation/Search",
|
||||
tintColor: self.theme.rootController.navigationBar.glassBarButtonForegroundColor
|
||||
tintColor: self.theme.chat.inputPanel.panelControlColor
|
||||
)
|
||||
)),
|
||||
action: { [weak self] _ in
|
||||
@@ -441,15 +443,17 @@ public final class AuthorizationSequenceCountrySelectionController: ViewControll
|
||||
self.closeButtonNode = closeButtonNode
|
||||
self.navigationItem.leftBarButtonItem = UIBarButtonItem(customDisplayNode: closeButtonNode)
|
||||
}
|
||||
|
||||
let searchButtonNode: BarComponentHostNode
|
||||
if let current = self.searchButtonNode {
|
||||
searchButtonNode = current
|
||||
searchButtonNode.component = searchComponent
|
||||
} else {
|
||||
searchButtonNode = BarComponentHostNode(component: searchComponent, size: barButtonSize)
|
||||
self.searchButtonNode = searchButtonNode
|
||||
self.navigationItem.rightBarButtonItem = UIBarButtonItem(customDisplayNode: searchButtonNode)
|
||||
|
||||
if !self.glass {
|
||||
let searchButtonNode: BarComponentHostNode
|
||||
if let current = self.searchButtonNode {
|
||||
searchButtonNode = current
|
||||
searchButtonNode.component = searchComponent
|
||||
} else {
|
||||
searchButtonNode = BarComponentHostNode(component: searchComponent, size: barButtonSize)
|
||||
self.searchButtonNode = searchButtonNode
|
||||
self.navigationItem.rightBarButtonItem = UIBarButtonItem(customDisplayNode: searchButtonNode)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user