summaryrefslogtreecommitdiff
path: root/src/trg-client.h
diff options
context:
space:
mode:
authorGravatar Alan Fitton <ajf@eth0.org.uk>2011-04-12 10:54:29 +0000
committerGravatar Alan Fitton <ajf@eth0.org.uk>2011-04-12 10:54:29 +0000
commit42eddac0e9f0216175fef223fd9b1023ed502a6e (patch)
tree7fd853c8fdabc678bc1df0f4eb5160420347ac8e /src/trg-client.h
parentf4a194f08d0c48641f5394cd07be61931a432241 (diff)
some quite significant changes to only receive/update recently-active torrents, if enabled. also use a hash table and tree row references for lookup. hopefully performance will be much better for people with large number of torrents.
Diffstat (limited to 'src/trg-client.h')
-rw-r--r--src/trg-client.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/trg-client.h b/src/trg-client.h
index 51d851d..480d828 100644
--- a/src/trg-client.h
+++ b/src/trg-client.h
@@ -20,6 +20,13 @@
#ifndef TRG_CLIENT_H_
#define TRG_CLIENT_H_
+#define TRANSMISSION_MIN_SUPPORTED 2.0
+
+#define TORRENT_GET_MODE_FIRST 0
+#define TORRENT_GET_MODE_ACTIVE 1
+#define TORRENT_GET_MODE_INTERACTION 2
+#define TORRENT_GET_MODE_UPDATE 3
+
#define TRG_GCONF_SCHEMA_ERROR -1
#define TRG_NO_HOSTNAME_SET -2
@@ -30,6 +37,7 @@
typedef struct {
char *session_id;
+ gboolean activeOnlyUpdate;
gint failCount;
gint interval;
gint64 updateSerial;
@@ -40,7 +48,7 @@ typedef struct {
char *username;
char *password;
char *proxy;
- JsonArray *torrents;
+ GHashTable *torrentTable;
GConfClient *gconf;
GMutex *updateMutex;
} trg_client;