~ubuntu-branches/ubuntu/maverick/transmission/maverick

« back to all changes in this revision

Viewing changes to gtk/conf.h

  • Committer: Bazaar Package Importer
  • Author(s): Philipp Benner
  • Date: 2006-08-29 20:50:41 UTC
  • Revision ID: james.westby@ubuntu.com-20060829205041-mzhpiqksdf7pbk17
Tags: upstream-0.6.1.dfsg
ImportĀ upstreamĀ versionĀ 0.6.1.dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
  $Id: conf.h 327 2006-06-11 05:04:27Z joshe $
 
3
 
 
4
  Copyright (c) 2005-2006 Joshua Elsasser. All rights reserved.
 
5
   
 
6
  Redistribution and use in source and binary forms, with or without
 
7
  modification, are permitted provided that the following conditions
 
8
  are met:
 
9
   
 
10
   1. Redistributions of source code must retain the above copyright
 
11
      notice, this list of conditions and the following disclaimer.
 
12
   2. Redistributions in binary form must reproduce the above copyright
 
13
      notice, this list of conditions and the following disclaimer in the
 
14
      documentation and/or other materials provided with the distribution.
 
15
   
 
16
  THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS "AS IS" AND
 
17
  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 
18
  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 
19
  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
 
20
  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 
21
  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 
22
  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 
23
  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 
24
  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 
25
  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 
26
  POSSIBILITY OF SUCH DAMAGE.
 
27
*/
 
28
 
 
29
#ifndef TG_CONF_H
 
30
#define TG_CONF_H
 
31
 
 
32
#include "transmission.h"
 
33
#include "bencode.h"
 
34
 
 
35
gboolean
 
36
cf_init(const char *confdir, char **errstr);
 
37
gboolean
 
38
cf_lock(char **errstr);
 
39
char *
 
40
cf_sockname(void);
 
41
void
 
42
cf_loadprefs(char **errstr);
 
43
const char *
 
44
cf_getpref(const char *name);
 
45
void
 
46
cf_setpref(const char *name, const char *value);
 
47
void
 
48
cf_saveprefs(char **errstr);
 
49
benc_val_t *
 
50
cf_loadstate(char **errstr);
 
51
void
 
52
cf_savestate(benc_val_t *state, char **errstr);
 
53
void
 
54
cf_freestate(benc_val_t *state);
 
55
 
 
56
/* macros for names of prefs we use */
 
57
#define PREF_PORT               "listening-port"
 
58
#define PREF_USEDOWNLIMIT       "use-download-limit"
 
59
#define PREF_DOWNLIMIT          "download-limit"
 
60
#define PREF_USEUPLIMIT         "use-upload-limit"
 
61
#define PREF_UPLIMIT            "upload-limit"
 
62
#define PREF_DIR                "download-directory"
 
63
#define PREF_ADDSTD             "add-behavior-standard"
 
64
#define PREF_ADDIPC             "add-behavior-ipc"
 
65
 
 
66
#endif /* TG_CONF_H */