use of com.meisolsson.githubsdk.model.TextMatch in project gh4a by slapperwan.
the class SearchFragment method openFileViewer.
private void openFileViewer(SearchCode result, int matchIndex) {
Repository repo = result.repository();
Uri uri = Uri.parse(result.url());
String ref = uri.getQueryParameter("ref");
TextMatch textMatch = matchIndex >= 0 ? result.textMatches().get(matchIndex) : null;
startActivity(FileViewerActivity.makeIntentWithSearchMatch(getActivity(), repo.owner().login(), repo.name(), ref, result.path(), textMatch));
}
Aggregations