-
Notifications
You must be signed in to change notification settings - Fork 143
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f07c737
commit 6a2ef73
Showing
14 changed files
with
131 additions
and
47 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
imageslider/src/main/java/com/denzcoskun/imageslider/ViewPagerScroller.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package com.denzcoskun.imageslider | ||
|
||
import android.content.Context | ||
import android.view.animation.Interpolator | ||
import android.widget.Scroller | ||
|
||
|
||
/** | ||
* Created by Deniz Coşkun on 05/04/2023. | ||
* denzcoskun@hotmail.com | ||
* İstanbul | ||
*/ | ||
class ViewPagerScroller : Scroller { | ||
|
||
var fixedDuration = 1000 //time to scroll in milliseconds | ||
|
||
constructor(context: Context) : super(context) | ||
|
||
constructor(context: Context, interpolator: Interpolator) : super(context, interpolator) | ||
|
||
constructor(context: Context, interpolator: Interpolator, flywheel: Boolean) : super(context, interpolator, flywheel) | ||
|
||
|
||
override fun startScroll(startX: Int, startY: Int, dx: Int, dy: Int, duration: Int) { | ||
super.startScroll(startX, startY, dx, dy, fixedDuration) | ||
} | ||
|
||
override fun startScroll(startX: Int, startY: Int, dx: Int, dy: Int) { | ||
super.startScroll(startX, startY, dx, dy, fixedDuration) | ||
} | ||
} |
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters