Mercurial > dwindows
diff ios/dw.m @ 2674:dd0b29320a3d
iOS: Use the claimed default value for the navigation bar of 44 points.
Then check to see if the intrinsicContentSize is different for us.
It is reporting a point size of 50 for me which corrects the look.
Also even more unicode in mobile.txt.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Mon, 18 Oct 2021 20:50:55 +0000 |
parents | a39e2ea6fa14 |
children | 24fb27a1e039 |
line wrap: on
line diff
--- a/ios/dw.m Mon Oct 18 13:29:55 2021 +0000 +++ b/ios/dw.m Mon Oct 18 20:50:55 2021 +0000 @@ -8071,9 +8071,18 @@ if(flStyle & DW_FCF_TITLEBAR) { NSInteger sbheight = [[[window windowScene] statusBarManager] statusBarFrame].size.height; - UINavigationBar* navbar = [[UINavigationBar alloc] initWithFrame:CGRectMake(0, sbheight, screenrect.size.width, 40)]; + CGRect navrect = CGRectMake(0, sbheight, screenrect.size.width, 44); + UINavigationBar* navbar = [[UINavigationBar alloc] initWithFrame:navrect]; UINavigationItem* navItem = [[UINavigationItem alloc] initWithTitle:nstitle]; + /* Double check the intrinsic height... */ + CGSize navdefault = [navbar intrinsicContentSize]; + if(navdefault.height != navrect.size.height) + { + navrect.size.height = navdefault.height; + navbar.frame = navrect; + } + /* We maintain a list of top-level windows...If there is more than one window, * and our window has the close button style, add a Back button that will close it. */