@@ 87-91 (lines=5) @@ | ||
84 | // Call the proper hook based on the context provided. |
|
85 | switch ( $context ) { |
|
86 | ||
87 | case 'form_top': |
|
88 | add_action( 'edit_form_top', array( $this, 'add_context_metabox' ) ); |
|
89 | add_filter( 'cmb2_wrap_classes', array( $this, 'add_context_class' ), 10, 2 ); |
|
90 | ||
91 | break; |
|
92 | ||
93 | case 'before_permalink': |
|
94 | add_action( 'edit_form_before_permalink', array( $this, 'add_context_metabox' ) ); |
|
@@ 93-97 (lines=5) @@ | ||
90 | ||
91 | break; |
|
92 | ||
93 | case 'before_permalink': |
|
94 | add_action( 'edit_form_before_permalink', array( $this, 'add_context_metabox' ) ); |
|
95 | add_filter( 'cmb2_wrap_classes', array( $this, 'add_context_class' ), 10, 2 ); |
|
96 | ||
97 | break; |
|
98 | ||
99 | case 'after_title': |
|
100 | add_action( 'edit_form_after_title', array( $this, 'add_context_metabox' ) ); |
|
@@ 99-103 (lines=5) @@ | ||
96 | ||
97 | break; |
|
98 | ||
99 | case 'after_title': |
|
100 | add_action( 'edit_form_after_title', array( $this, 'add_context_metabox' ) ); |
|
101 | add_filter( 'cmb2_wrap_classes', array( $this, 'add_context_class' ), 10, 2 ); |
|
102 | ||
103 | break; |
|
104 | ||
105 | case 'after_editor': |
|
106 | add_action( 'edit_form_after_editor', array( $this, 'add_context_metabox' ) ); |
|
@@ 105-109 (lines=5) @@ | ||
102 | ||
103 | break; |
|
104 | ||
105 | case 'after_editor': |
|
106 | add_action( 'edit_form_after_editor', array( $this, 'add_context_metabox' ) ); |
|
107 | add_filter( 'cmb2_wrap_classes', array( $this, 'add_context_class' ), 10, 2 ); |
|
108 | ||
109 | break; |
|
110 | ||
111 | default: |
|
112 | add_action( 'add_meta_boxes', array( $this, 'add_metaboxes' ) ); |