summarylogtreecommitdiffstats
path: root/disable_version_check.patch
diff options
context:
space:
mode:
Diffstat (limited to 'disable_version_check.patch')
-rw-r--r--disable_version_check.patch175
1 files changed, 86 insertions, 89 deletions
diff --git a/disable_version_check.patch b/disable_version_check.patch
index 968b7a6652fc..6eb142c5e585 100644
--- a/disable_version_check.patch
+++ b/disable_version_check.patch
@@ -1,90 +1,87 @@
# disable version check. updates come via package management
-diff --git a/src/chatty/Chatty.java b/src/chatty/Chatty.java
-index 2fdc077..5c39dd8 100644
---- a/src/chatty/Chatty.java
-+++ b/src/chatty/Chatty.java
-@@ -53,7 +53,7 @@ public class Chatty {
- * Enable Version Checker (if you compile and distribute this yourself, you
- * may want to disable this)
- */
-- public static final boolean VERSION_CHECK_ENABLED = true;
-+ public static final boolean VERSION_CHECK_ENABLED = false;
-
- /**
- * The regular URL of the textfile where the most recent version is stored.
-diff --git a/src/chatty/TwitchClient.java b/src/chatty/TwitchClient.java
-index 8bea1db..b900837 100644
---- a/src/chatty/TwitchClient.java
-+++ b/src/chatty/TwitchClient.java
-@@ -262,7 +262,7 @@ public class TwitchClient {
- checkForVersionChange();
- // Check version, if enabled in this build
- if (Chatty.VERSION_CHECK_ENABLED) {
-- checkNewVersion();
-+ //checkNewVersion();
- }
-
- // Connect or open connect dialog
-@@ -370,44 +370,7 @@ public class TwitchClient {
- * Checks for a new version if the last check was long enough ago.
- */
- private void checkNewVersion() {
-- if (!settings.getBoolean("checkNewVersion")) {
-- return;
-- }
-- /**
-- * Check if enough time has passed since the last check.
-- */
-- long ago = System.currentTimeMillis() - settings.getLong("versionLastChecked");
-- if (ago/1000 < CHECK_VERSION_INTERVAL) {
-- /**
-- * If not checking, check if update was detected last time.
-- */
-- String updateAvailable = settings.getString("updateAvailable");
-- if (!updateAvailable.isEmpty()) {
-- g.setUpdateAvailable(updateAvailable);
-- }
-- return;
-- }
-- settings.setLong("versionLastChecked", System.currentTimeMillis());
-- g.printSystem("Checking for new version..");
-
-- new Version(new VersionListener() {
--
-- @Override
-- public void versionChecked(String version, String info, boolean isNewVersion) {
-- if (isNewVersion) {
-- String infoText = "";
-- if (!info.isEmpty()) {
-- infoText = "[" + info + "] ";
-- }
-- g.printSystem("New version available: "+version+" "+infoText
-- +"(Go to <Help-Website> to download)");
-- g.setUpdateAvailable(version);
-- settings.setString("updateAvailable", version);
-- } else {
-- g.printSystem("You already have the newest version.");
-- }
-- }
-- });
- }
-
- /**
-diff --git a/src/chatty/Version.java b/src/chatty/Version.java
-index 2f6d9c4..6ac5227 100644
---- a/src/chatty/Version.java
-+++ b/src/chatty/Version.java
-@@ -32,8 +32,8 @@ public class Version {
- }
-
- private void checkForNewVersion() {
-- LOGGER.info("Checking for new version..");
-- new Thread(new VersionChecker()).start();
-+ //LOGGER.info("Checking for new version..");
-+ //new Thread(new VersionChecker()).start();
- }
-
- /**
---
-2.5.0
-
+Index: chatty-0.8.2/src/chatty/Chatty.java
+===================================================================
+--- chatty-0.8.2.orig/src/chatty/Chatty.java 2016-04-26 22:46:41.680640379 +0200
++++ chatty-0.8.2/src/chatty/Chatty.java 2016-04-26 22:50:03.208841787 +0200
+@@ -58,7 +58,7 @@
+ * Enable Version Checker (if you compile and distribute this yourself, you
+ * may want to disable this)
+ */
+- public static final boolean VERSION_CHECK_ENABLED = true;
++ public static final boolean VERSION_CHECK_ENABLED = false;
+
+ /**
+ * The regular URL of the textfile where the most recent version is stored.
+Index: chatty-0.8.2/src/chatty/TwitchClient.java
+===================================================================
+--- chatty-0.8.2.orig/src/chatty/TwitchClient.java 2016-04-26 22:47:26.953580371 +0200
++++ chatty-0.8.2/src/chatty/TwitchClient.java 2016-04-26 22:51:15.054348837 +0200
+@@ -298,7 +298,7 @@
+ checkForVersionChange();
+ // Check version, if enabled in this build
+ if (Chatty.VERSION_CHECK_ENABLED) {
+- checkNewVersion();
++ //checkNewVersion();
+ }
+
+ // Connect or open connect dialog
+@@ -368,44 +368,7 @@
+ * Checks for a new version if the last check was long enough ago.
+ */
+ private void checkNewVersion() {
+- if (!settings.getBoolean("checkNewVersion")) {
+- return;
+- }
+- /**
+- * Check if enough time has passed since the last check.
+- */
+- long ago = System.currentTimeMillis() - settings.getLong("versionLastChecked");
+- if (ago/1000 < CHECK_VERSION_INTERVAL) {
+- /**
+- * If not checking, check if update was detected last time.
+- */
+- String updateAvailable = settings.getString("updateAvailable");
+- if (!updateAvailable.isEmpty()) {
+- g.setUpdateAvailable(updateAvailable);
+- }
+- return;
+- }
+- settings.setLong("versionLastChecked", System.currentTimeMillis());
+- g.printSystem("Checking for new version..");
+-
+- new Version(new VersionListener() {
+
+- @Override
+- public void versionChecked(String version, String info, boolean isNewVersion) {
+- if (isNewVersion) {
+- String infoText = "";
+- if (!info.isEmpty()) {
+- infoText = "[" + info + "] ";
+- }
+- g.printSystem("New version available: "+version+" "+infoText
+- +"(Go to <Help-Website> to download)");
+- g.setUpdateAvailable(version);
+- settings.setString("updateAvailable", version);
+- } else {
+- g.printSystem("You already have the newest version.");
+- }
+- }
+- });
+ }
+
+ /**
+Index: chatty-0.8.2/src/chatty/Version.java
+===================================================================
+--- chatty-0.8.2.orig/src/chatty/Version.java 2016-04-26 22:47:26.953580371 +0200
++++ chatty-0.8.2/src/chatty/Version.java 2016-04-26 22:51:48.071042729 +0200
+@@ -32,8 +32,8 @@
+ }
+
+ private void checkForNewVersion() {
+- LOGGER.info("Checking for new version..");
+- new Thread(new VersionChecker()).start();
++ //LOGGER.info("Checking for new version..");
++ //new Thread(new VersionChecker()).start();
+ }
+
+ /**