Skip to content

[iOS] Decouple top app nav bar visibility from annotation toolbar visibility#356

Open
eslamwael74 wants to merge 5 commits into
ApryseSDK:masterfrom
eslamwael74:hotfix/ios-hide-top-app-nav-only
Open

[iOS] Decouple top app nav bar visibility from annotation toolbar visibility#356
eslamwael74 wants to merge 5 commits into
ApryseSDK:masterfrom
eslamwael74:hotfix/ios-hide-top-app-nav-only

Conversation

@eslamwael74

Copy link
Copy Markdown
Contributor

Summary

  • Allow hideTopAppNavBar on iOS to hide only the top app navigation bar.
  • Keep annotation toolbars visible when hideTopAppNavBar is enabled.
  • Bump package version to 1.0.1-57.
  • Add changelog entry.

Why

Previously, hideTopAppNavBar also disabled the top annotation toolbar because isTopToolbarEnabled depended on both topAppNavBarHidden and topToolbarsHidden.

This made it impossible to hide the iOS top app navigation bar while still showing annotation tools.

Changes

  • Make annotation toolbar visibility depend on topToolbarsHidden.
  • Keep navigation bar visibility controlled by topAppNavBarHidden.
  • Preserve translucent toolbar behavior when either top app nav or top toolbars are hidden.

…ibility

* Allow hiding the iOS top app navigation bar without hiding annotation toolbars
* Update changelog
* Updating pubspec.yaml
* Updating package version
Copilot AI review requested due to automatic review settings June 21, 2026 15:38

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the iOS viewer controller logic so hideTopAppNavBar can hide only the app navigation bar while keeping annotation toolbars visible, and publishes the change as 1.0.1-57 with a changelog entry.

Changes:

  • Decouple top annotation toolbar enablement from topAppNavBarHidden (iOS).
  • Adjust iOS viewer settings to preserve translucency behavior when top UI is hidden.
  • Bump package version and add a 1.0.1-57 changelog entry.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
pubspec.yaml Bumps package version to 1.0.1-57.
ios/Classes/PTFlutterDocumentController.m Updates iOS toolbar/nav-bar visibility logic to decouple app nav bar hiding from annotation toolbar hiding.
CHANGELOG.md Adds release notes for 1.0.1-57.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread ios/Classes/PTFlutterDocumentController.m Outdated
Comment thread ios/Classes/PTFlutterDocumentController.m Outdated
* Update navigation bar visibility to account for top toolbars state
* Hide navigation bar when top toolbars are hidden

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

Comment on lines 159 to 163
if ([self isTopToolbarEnabled]) {
if (![self isNavigationBarEnabled]) {
return NO;
}
return [self.navigationController isNavigationBarHidden];

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot This is intentional for this PR. When hideTopAppNavBar is enabled, the native navigation bar is hidden, but the annotation/top toolbar should remain visible. Returning [super controlsHidden] here causes both bars to be hidden, which breaks the decoupling this PR is adding. So return NO is required to keep toolbar visibility independent from the app nav bar.

Comment thread ios/Classes/PTFlutterDocumentController.m
* Prevent showing the navigation bar when top toolbars are hidden.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants