|
@@ -6,6 +6,7 @@ import android.support.annotation.NonNull;
|
6
|
6
|
import android.support.annotation.Nullable;
|
7
|
7
|
import android.support.v4.widget.DrawerLayout;
|
8
|
8
|
import android.support.v7.app.AppCompatActivity;
|
|
9
|
+import android.util.Log;
|
9
|
10
|
import android.view.View;
|
10
|
11
|
import android.widget.RelativeLayout;
|
11
|
12
|
|
|
@@ -333,7 +334,13 @@ public class BottomTabsLayout extends BaseLayout implements AHBottomNavigation.O
|
333
|
334
|
}
|
334
|
335
|
|
335
|
336
|
public void selectBottomTabByNavigatorId(String navigatorId) {
|
336
|
|
- bottomTabs.setCurrentItem(getScreenStackIndex(navigatorId));
|
|
337
|
+ try {
|
|
338
|
+ bottomTabs.setCurrentItem(getScreenStackIndex(navigatorId));
|
|
339
|
+ } catch (ScreenStackNotFoundException e) {
|
|
340
|
+ Log.e("BottomTabsLayout", "Could not select bottom tab by navigatorId [" + navigatorId + "]." +
|
|
341
|
+ "This should not have happened, it probably means navigator.switchToTab()" +
|
|
342
|
+ "was called from an unmounted tab.");
|
|
343
|
+ }
|
337
|
344
|
}
|
338
|
345
|
|
339
|
346
|
private boolean hasBackgroundColor(StyleParams params) {
|