File tree 1 file changed +13
-2
lines changed
app/src/main/java/com/donnfelker/android/bootstrap/ui
1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change 22
22
import com .donnfelker .android .bootstrap .Injector ;
23
23
import com .donnfelker .android .bootstrap .R ;
24
24
import com .donnfelker .android .bootstrap .events .NavItemSelectedEvent ;
25
+ import com .donnfelker .android .bootstrap .util .UIUtils ;
25
26
import com .squareup .otto .Bus ;
26
27
27
28
import javax .inject .Inject ;
@@ -213,8 +214,18 @@ public void onSaveInstanceState(Bundle outState) {
213
214
@ Override
214
215
public void onConfigurationChanged (Configuration newConfig ) {
215
216
super .onConfigurationChanged (newConfig );
216
- // Forward the new configuration the drawer toggle component.
217
- drawerToggle .onConfigurationChanged (newConfig );
217
+
218
+ if (!isTablet ()) {
219
+ // Forward the new configuration the drawer toggle component.
220
+ drawerToggle .onConfigurationChanged (newConfig );
221
+ }
222
+ }
223
+
224
+ private boolean isTablet () {
225
+ if (getActivity () != null ) {
226
+ return UIUtils .isTablet (getActivity ());
227
+ }
228
+ return false ;
218
229
}
219
230
220
231
@ Override
You can’t perform that action at this time.
0 commit comments