iOS Question CLVHeader Scroll With NavBar

jahswant

Well-Known Member
Licensed User
Longtime User
I found out that in the CLVHeader scroll with xcode13 and ios 15 the NavBar color changes. How to disable this behavior ?
 
Solution
This issue has nothing to do with CLVHeader. Correct way to set the bar color:
B4X:
Dim no As NativeObject = NavControl
Dim clr As Int = 0xFF00BCD4
no.GetField("navigationBar").RunMethod("setBarTintColor:", Array(no.ColorToUIColor(clr)))
no.GetField("view").As(View).Color = clr
no.GetField("navigationBar").RunMethod("setTintColor:", Array(no.ColorToUIColor(clr)))

jahswant

Well-Known Member
Licensed User
Longtime User
pl
I've tested it with B4i v7.80 and don't see any color change. Are you using an older version?
please add this in the Application_Start

B4X:
NavControl.As(NativeObject).GetField("view").As(B4XView).Color = 0xFF00BCD4


Then scroll you'll see a color change on the nav bar.
 
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
This issue has nothing to do with CLVHeader. Correct way to set the bar color:
B4X:
Dim no As NativeObject = NavControl
Dim clr As Int = 0xFF00BCD4
no.GetField("navigationBar").RunMethod("setBarTintColor:", Array(no.ColorToUIColor(clr)))
no.GetField("view").As(View).Color = clr
no.GetField("navigationBar").RunMethod("setTintColor:", Array(no.ColorToUIColor(clr)))
 
Upvote 1
Solution
Top