Comments (3)
First I just want to point out that it is intentional that GandalfActivity
blocks the UI. This is because when issuing a force update it is usually related to some unforeseen event or bug found in the future. Without knowing which section of the app the update is for you risk executing code that should not be executing before the Gandalf check can complete.
But Gandalf is built in such a way that you can use it however you would like to get the same update functionality. The README
has a quick explanation about using Gandalf without the Activity
approach:
If extending GandalfActivity doesn't work for you the Gandalf class can be used directly by calling shallIPass(GandalfCallback callback). In this case make sure you respond to the callback methods and make a call to gandalf.save(Alert alert) and gandalf.save(OptionalUpdate optionalUpdate) if not using the BootstrapDialogUtil for your UI.
Let me know if that isn't clear enough or you need a little more direction.
from gandalf.
OK, thanks. I got your point why using a splash activity makes sense.
Another idea to minimize the unwanted delay could be adjusting the http request timeout as this especially happens with bad internet connection. However, this would increase the risk of passing the check simply due to a timeout.
from gandalf.
That is a possible solution to avoid long delays during the Gandalf check. You can accomplish this by passing a custom OkHttpClient
to the Installer
and setting your own timeout length. The current default for Gandalf is set to 30 seconds.
from gandalf.
Related Issues (20)
- Fix Travis build issue with javadoc generation
- Add screenshots from example app to README/page HOT 2
- Update README for custom dialog content
- Major versions and minor versions not supported HOT 3
- Download update from custom url HOT 3
- The library is outdated in jcenter repository HOT 6
- Application label causing manifest merger issues HOT 8
- Blocking alert not shown when user skips optional update HOT 5
- Auto install apk when using FileDownloadUpdateListener HOT 9
- Update dependencies to the current latest versions HOT 2
- Semantic version numbers can cause app crash HOT 20
- Add the ability to set a custom version checker
- Add a debug mode to the installer HOT 1
- Gradle Error: Cannot create variant 'android-lint' after configuration ':gandalf:debugRuntimeElements' has been resolved HOT 2
- Add check when application is foregrounded.
- Gandalf not working in Samsung 10 HOT 1
- Found DiskReadViolation when strict mode enabled HOT 1
- StrictMode policy violation found when doing Gson mapping from onResponse() call HOT 3
- Consider adding an dependency other than jCenter?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gandalf.