Hello guys,
I have module named About, here are the code for BuildPage
On module ABMApplication, here is the declaration to point to that page
On module ABMShared, here are the codes in BuildTheme for ActiveForeColor
On module ABMApplication, here are the codes in BuildNavigationBar
But Sidebar Item Active foreground color didn't change to color amber.
It seem that About Page is not active, so the color didn't change, where did I miss?
I have module named About, here are the code for BuildPage
B4X:
public Sub BuildPage()
BuildTheme
page.InitializeWithTheme(Name, "/ws/" & ABMShared.AppName & "/" & Name, False, ABMShared.SessionMaxInactiveIntervalSeconds, theme)
page.ShowLoader=True
page.PageTitle = "About"
page.PageHTMLName = "about.html"
page.ShowConnectedIndicator = True
ABMShared.BuildNavigationBar(page, "Web APP","../images/logo.png", "", "", "")
page.AddRowsM(1,True,0,0, "").AddCells12MP(1,0,0,0,0,"")
page.BuildGrid
End Sub
On module ABMApplication, here is the declaration to point to that page
B4X:
Sub Class_Globals
Private InitialPage As String = "About/about.html"
End Sub
On module ABMShared, here are the codes in BuildTheme for ActiveForeColor
B4X:
Sub BuildTheme(themeName As String)
MyTheme.Initialize(themeName)
MyTheme.AddNavigationBarTheme("nav1theme") MyTheme.NavigationBar("nav1theme").SideBarActiveForeColor = ABM.COLOR_AMBER
MyTheme.NavigationBar("nav1theme").SideBarSubActiveForeColor = ABM.COLOR_AMBER
MyTheme.NavigationBar("nav1theme").SideBarSubActiveForeColorIntensity = ABM.INTENSITY_DARKEN3
End Sub
B4X:
Sub BuildNavigationBar(page As ABMPage, Title As String, logo As String, ActiveTopReturnName As String, ActiveSideReturnName As String, ActiveSideSubReturnName As String) 'ignore
Dim sbtopimg As ABMImage
Private Wdth = 250 As Int
page.NavigationBar.Initialize(page, "nav1", ABM.SIDEBAR_MANUAL_ALWAYSHIDE, Title, True, True, Wdth, 49, sbtopimg, ABM.COLLAPSE_ACCORDION, "nav1theme")
page.NavigationBar.IsTextSelectable = False
page.NavigationBar.TopBarDropDownConstrainWidth = False
page.NavigationBar.ActiveTopReturnName = ActiveTopReturnName
page.NavigationBar.ActiveSideReturnName = ActiveSideReturnName
page.NavigationBar.ActiveSideSubReturnName = ActiveSideSubReturnName
page.NavigationBar.AddSideBarDivider
page.NavigationBar.AddSideBarItem("About", "About", "mdi-action-dashboard", "../About/about.html")
End Sub
But Sidebar Item Active foreground color didn't change to color amber.
It seem that About Page is not active, so the color didn't change, where did I miss?