Astra_UberMenu_Pro::disable_above_below_header_toggle()
Disable the Mobile Menu toggles from Astra if Uber Menu is used.
Description
Source
File: compatibility/class-astra-ubermenu-pro.php
public function disable_above_below_header_toggle() { // Don't overrde anythign if ubermenu's function is not present. if ( ! function_exists( 'ubermenu_get_menu_instance_by_theme_location' ) ) { return; } if ( ! class_exists( 'Astra_Ext_Header_Sections_Markup' ) ) { return; } $hs_class = Astra_Ext_Header_Sections_Markup::get_instance(); $ubermenu_above_header = ubermenu_get_menu_instance_by_theme_location( 'above_header_menu' ); $ubermenu_below_header = ubermenu_get_menu_instance_by_theme_location( 'below_header_menu' ); if ( '' !== $ubermenu_above_header && false != $ubermenu_above_header ) { remove_action( 'astra_above_header_toggle_buttons', array( $hs_class, 'above_header_toggle_button' ), 10 ); } if ( '' !== $ubermenu_below_header && false != $ubermenu_below_header ) { remove_action( 'astra_below_header_toggle_buttons', array( $hs_class, 'below_header_toggle_button' ), 11 ); } }
Expand full source code Collapse full source code View on Trac
Changelog
Version | Description |
---|---|
1.1.7 | Introduced. |