Turbolinks 5を使用しているAndroidでは、古典的なTurbolinksの切り替えは行われません(途中に白いページがなく、水平の進行状況バーが表示されません)。だから、私はMainActivity.java私 Android Turbolinksでは、デフォルトのスピナーを置き換えるカスタムのprogressViewを作成する方法は?
activity_main.xmlで progressView = new ProgressBar(turbolinksView.getContext());
TurbolinksSession.getDefault(this)
.activity(this)
.adapter(this)
.view(turbolinksView)
.progressView(progressView, R.id.indeterminateBar, 300)
.visit(location);
と、この中でこれを持って、私は私自身のprogressViewを必要とするが、私は
間違っているかもしれないと思います
<ProgressBar
android:id="@+id/indeterminateBar"
android:layout_width="wrap_content"
style="@android:style/Widget.ProgressBar.Horizontal"
android:layout_height="wrap_content"
/>
階調設定が
compileSdkVersion 26
minSdkVersion 19
targetSdkVersion 22
私はIllegalArgumentException "A progress indicator view must be provided in your custom progressView."
を得る上で私は
.progressView(progressView, progressView.getId(), 300)
を試してみましたが、私はまだIllegalArgumentException "A progress indicator view must be provided in your custom progressView."
は明らかに私は右progressView
をインスタンス化することができません取得し、私の質問はどのように私は何をすべきかである実行右を取得/作成するprogressView
??クロスを事前に
謝罪、私はそれをここに掲載唯一の理由は、あまりにも私が日
おかげで働いていた:あなたのMainActivity.java上
。 – daya