forked from organicmaps/organicmaps
[android] Fixed NPE on webview in bookmark catalog, changed order of initialization
This commit is contained in:
parent
707a497f1f
commit
40f303350c
1 changed files with 6 additions and 5 deletions
|
@ -158,6 +158,12 @@ public class BookmarksCatalogFragment extends BaseWebViewMwmFragment
|
|||
{
|
||||
setHasOptionsMenu(true);
|
||||
|
||||
View root = inflater.inflate(R.layout.fragment_bookmarks_catalog, container, false);
|
||||
mWebView = root.findViewById(getWebViewResId());
|
||||
mRetryBtn = root.findViewById(R.id.retry_btn);
|
||||
mProgressView = root.findViewById(R.id.progress);
|
||||
initWebView();
|
||||
|
||||
mFailedPurchaseController = PurchaseFactory.createFailedBookmarkPurchaseController(requireContext());
|
||||
mFailedPurchaseController.initialize(requireActivity());
|
||||
mPurchaseChecker = new FailedBookmarkPurchaseChecker();
|
||||
|
@ -169,11 +175,6 @@ public class BookmarksCatalogFragment extends BaseWebViewMwmFragment
|
|||
mProductDetailsLoadingCallback = new ProductDetailsLoadingCallback();
|
||||
mProductDetailsLoadingManager.addCallback(mProductDetailsLoadingCallback);
|
||||
|
||||
View root = inflater.inflate(R.layout.fragment_bookmarks_catalog, container, false);
|
||||
mWebView = root.findViewById(getWebViewResId());
|
||||
mRetryBtn = root.findViewById(R.id.retry_btn);
|
||||
mProgressView = root.findViewById(R.id.progress);
|
||||
initWebView();
|
||||
mRetryBtn.setOnClickListener(v -> onRetryClick());
|
||||
mDelegate.onCreateView(savedInstanceState);
|
||||
return root;
|
||||
|
|
Loading…
Add table
Reference in a new issue