0

previousBttnnextBttnとして知られている2つのボタンがありますscrollView。に3つの画像がありscrollViewます。

  1. 私はこのように隠したいpreviousBttn:[...]>最初の画像で

  2. 2番目の画像をクリックするnextBttnと、2つのボタンが次のように表示されます。<[...]>

  3. 最後に、3番目の画像で、nextBttnが非表示になり、previousBttnは次のように表示されます。<[...]

    プロセス:[...]> <[...]> <[...]

swipeまた、私たち全員が画像を作成する場合も同じです。

4

2 に答える 2

1

私はあなたがそれをあなた自身でしなければならないと思います。現在表示されているページのインデックスと合計画像数がわかります。if(index == 0)hidePreviousButtonORShowThis[...]>。else if(index == totalImageCount-1)then hiddenNextButtonelseUnhideBothButtons。

これらの標識に画像を使用できます[...]><[...]<[...]>

于 2013-03-26T07:33:58.517 に答える
0
    int currentIndex = 0;   // set to first postion
    // if you are at first position
    if(currentIndex == 0)
    {
        // hide previous button
    }
    else if(currentIndex == yourImageCount)
    {
        // hide next button
    }
    else
    {
        // show both the buttons
    }
于 2013-03-26T08:15:49.253 に答える