diff --git a/source/net/filebot/ui/SupportDialog.java b/source/net/filebot/ui/SupportDialog.java index 0050f91a..ab787e7f 100644 --- a/source/net/filebot/ui/SupportDialog.java +++ b/source/net/filebot/ui/SupportDialog.java @@ -46,6 +46,16 @@ public enum SupportDialog { return "Please Donate"; } + @Override + public boolean feelingLucky(int sessionRenameCount, int totalRenameCount, int currentRevision, int lastSupportRevision, int supportRevisionCount) { + // annoy users that chose not to purchase FileBot + if (this == Donation && sessionRenameCount > 0 && "Windows 10".equals(System.getProperty("os.name"))) { + return true; + } + + return super.feelingLucky(sessionRenameCount, totalRenameCount, currentRevision, lastSupportRevision, supportRevisionCount); + } + @Override String getURI() { return getDonateURL(); @@ -78,6 +88,21 @@ public enum SupportDialog { return "Please write a Review"; } + @Override + public boolean feelingLucky(int sessionRenameCount, int totalRenameCount, int currentRevision, int lastSupportRevision, int supportRevisionCount) { + // ask for reviews at most once per revision + if (currentRevision <= lastSupportRevision) { + return false; + } + + // ask for reviews only when a significant number of files have been processed + if (sessionRenameCount < 3 || totalRenameCount < 3000) { + return false; + } + + return super.feelingLucky(sessionRenameCount, totalRenameCount, currentRevision, lastSupportRevision, supportRevisionCount); + } + @Override String getURI() { return getAppStoreLink(); @@ -86,16 +111,6 @@ public enum SupportDialog { }; public boolean feelingLucky(int sessionRenameCount, int totalRenameCount, int currentRevision, int lastSupportRevision, int supportRevisionCount) { - // ask for reviews at most once per revision - if (isAppStore() && currentRevision <= lastSupportRevision) { - return false; - } - - // ask for reviews only when a significant number of files have been processed - if (isAppStore() && (sessionRenameCount < 5 || totalRenameCount < 5000)) { - return false; - } - // ask for reviews at most every once in a while if (Math.random() <= 0.777) { return false;