Searches for the list view, which is contained by the dialog, in order to register a scroll
listener.

@param view
The view, which should be searched, as an instance of the class {@link ViewGroup}.
The view may not be null
503624
private boolean findListView(@NonNull final View view) {
        if (view instanceof AbsListView) {
            this.listView = (AbsListView) view;
            this.listView.setOnScrollListener(createListViewScrollListener());
            return true;
        } else if (view instanceof ViewGroup) {
            ViewGroup viewGroup = (ViewGroup) view;

            for (int i = 0; i < viewGroup.getChildCount(); i++) {
                if (findListView(viewGroup.getChildAt(i))) {
                    return true;
                }
            }
        }

        return false;
    }
581392
public void scrollDown() {
        logger.entering();
        WebElement webElement = this.findElement(By.className(SCROLLVIEW_CLASS));
        swipeDown(webElement);
        logger.exiting();
    }
995835
@NonNull public static <T> List<T> findByClass(@NonNull View rootView, Class<T> classType) {
        ViewGroup viewGroup = (ViewGroup) rootView.findViewById(android.R.id.content);
        return viewGroup == null ? new ArrayList<T>() : findByClass(viewGroup, classType);
    }
1190696
public void setView(boolean view) {
        PdfDictionary usage = getUsage();
        PdfDictionary dic = new PdfDictionary();
        dic.put(PdfName.VIEWSTATE, view ? PdfName.ON : PdfName.OFF);
        usage.put(PdfName.VIEW, dic);
    }
81070
@SuppressWarnings({"WeakerAccess", "unused"}) // For library users
    public void registerWidget(View widget) {
        prepareWidget(widget);

        if (widget instanceof AlgoliaResultsListener) {
            AlgoliaResultsListener listener = (AlgoliaResultsListener) widget;
            if (!this.resultListeners.contains(listener)) {
                this.resultListeners.add(listener);
            }
            searcher.registerResultListener(listener);
        }
        if (widget instanceof AlgoliaErrorListener) {
            AlgoliaErrorListener listener = (AlgoliaErrorListener) widget;
            if (!this.errorListeners.contains(listener)) {
                this.errorListeners.add(listener);
            }
            searcher.registerErrorListener(listener);
        }
        if (widget instanceof AlgoliaSearcherListener) {
            AlgoliaSearcherListener listener = (AlgoliaSearcherListener) widget;
            listener.initWithSearcher(searcher);
        }
    }
1079733
public void addFooterView(View view, int index, ViewGroup.LayoutParams lp) {
        mFooter.addView(view, index, lp);
    }
294917
public void setClearView(View view) {
        mClearView = view;
        if (view != null) {
            view.setVisibility(mOpened ? VISIBLE : INVISIBLE);
            view.setOnClickListener(mOnClickListenerClearView);
        }
    }
774656
public boolean waitForView(View view){
		View viewToWaitFor = waitForView(view, Timeout.getLargeTimeout(), true, true);
		if(viewToWaitFor != null) {
			return true;
		}
		
		return false;
		
	}
1149490
public void setEmptyView(View emptyView){
        if(this.emptyView != null){
            unregisterAdapterDataObserver(mEmptyObserver);
        }
        this.emptyView = emptyView;
        registerAdapterDataObserver(mEmptyObserver);
    }
767864
public void show(final View view) {
        if (view.getVisibility() != View.VISIBLE) {
            view.setAlpha(0);
            view.setVisibility(View.VISIBLE);
            if (durationSet) {
                view.animate().setDuration(duration);
            }
            view.animate().alpha(1);
        }
    }
1311976
public <T extends View> boolean searchFor(Set<T> uniqueViews, Class<T> viewClass, final int index) {
		ArrayList<T> allViews = RobotiumUtils.removeInvisibleViews(viewFetcher.getCurrentViews(viewClass, true));

		int uniqueViewsFound = (getNumberOfUniqueViews(uniqueViews, allViews));

		if(uniqueViewsFound > 0 && index < uniqueViewsFound) {
			return true;
		}

		if(uniqueViewsFound > 0 && index == 0) {
			return true;
		}
		return false;
	}
137039
public void onPostBindView(IDrawerItem drawerItem, View view) {
        if (mOnPostBindViewListener != null) {
            mOnPostBindViewListener.onBindView(drawerItem, view);
        }
    }
378614
public <T extends View> boolean waitForView(View view){
		if(config.commandLogging){
			Log.d(config.commandLoggingTag, "waitForView("+view+")");
		}
		
		return waiter.waitForView(view);
	}
167271
public void registerView(final String type, final Pair<View, View> view) {
        registeredViews.put(type, view);
    }
665893
public void scrollUp() {
        logger.entering();
        WebElement webElement = this.findElement(By.className(SCROLLVIEW_CLASS));
        swipeUp(webElement);
        logger.exiting();
    }
563401
@MainThread
    private void subscribeViewStateConsumerActually(@NonNull final V view) {

        if (view == null) {
            throw new NullPointerException("View is null");
        }

        if (viewStateConsumer == null) {
            throw new NullPointerException(ViewStateConsumer.class.getSimpleName()
                    + " is null. This is a Mosby internal bug. Please file an issue at https://github.com/sockeqwe/mosby/issues");
        }

        viewRelayConsumerDisposable = viewStateBehaviorSubject.subscribe(new Consumer<VS>() {
            @Override
            public void accept(VS vs) throws Exception {
                viewStateConsumer.accept(view, vs);
            }
        });
    }
888253
public final void registerView(final View view) {
        mActivity.runOnUiThread(new Runnable() {
            @Override
            public void run() {
                if (null != mRenderableViewGroup && view.getParent() != mRenderableViewGroup) {
                    /* The full screen should be updated otherwise just the children's bounds may be refreshed. */
                    mRenderableViewGroup.setClipChildren(false);
                    mRenderableViewGroup.addView(view);
                }
            }
        });
    }