Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gdacciaro/iOSDialog
iOS UIAlertView on Android.
https://github.com/gdacciaro/iOSDialog
android android-dialog android-dialog-view android-library iosdialog
Last synced: 2 days ago
JSON representation
iOS UIAlertView on Android.
- Host: GitHub
- URL: https://github.com/gdacciaro/iOSDialog
- Owner: gdacciaro
- License: mit
- Created: 2017-09-05T21:16:53.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-09-27T09:59:39.000Z (about 5 years ago)
- Last Synced: 2024-08-03T10:21:03.191Z (3 months ago)
- Topics: android, android-dialog, android-dialog-view, android-library, iosdialog
- Language: Java
- Homepage: http://gdacciaro.com
- Size: 171 KB
- Stars: 83
- Watchers: 4
- Forks: 25
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-mobile-collections - Type 2
README
# iOSDialog - iOS UIAlertView on Android
With this library you can use iOS UIAlertView on Android.
Two Buttons
One Button
To install the library just add this line to your gradle:
implementation 'com.gdacciaro:iosdialog:1.0.3'
And add this where you want:new iOSDialogBuilder(MainActivity.this)
.setTitle(getString(R.string.example_title))
.setSubtitle(getString(R.string.example_subtitle))
.setBoldPositiveLabel(true)
.setCancelable(false)
.setPositiveListener(getString(R.string.ok),new iOSDialogClickListener() {
@Override
public void onClick(iOSDialog dialog) {
Toast.makeText(MainActivity.this,"Clicked!",Toast.LENGTH_LONG).show();
dialog.dismiss();}
})
.setNegativeListener(getString(R.string.dismiss), new iOSDialogClickListener() {
@Override
public void onClick(iOSDialog dialog) {
dialog.dismiss();
}
})
.build().show();
If you liked this library, add a star to this project and feel free to make a fork!
A special thanks to Rofiq Setiawan who made a porting of iOSDialog for Xamarin.
Check it out here: https://github.com/rofiqsetiawan/iOSDialog
Another special thanks to Francesco Borrelli who helped me with the implementation of the iOSDialogClickListener
Here is his Linkedin profile https://www.linkedin.com/in/francesco-borrelli1/