~ubuntu-branches/debian/jessie/banshee-community-extensions/jessie

« back to all changes in this revision

Viewing changes to src/Lirc/Banshee.Lirc/LircClient.cs

  • Committer: Bazaar Package Importer
  • Author(s): Chow Loong Jin
  • Date: 2011-05-05 06:59:58 UTC
  • mfrom: (1.2.8 upstream)
  • Revision ID: james.westby@ubuntu.com-20110505065958-ffa74rsoxw05ir36
Tags: 2.0.1-1
* [c02b8fd] Move over to bz2 in debian/watch
* [536b6d6] New upstream bugfix release:
  + ClutterFlow: Fix NRE crash (bgo#647134)
  + Karaoke: add an gst_init() call to make sure gstreamer is working
  + Karaoke: fix NRE on dispose if audiokaraoke was not found
  + LastfmFingerprint: Don't strdup strings
  + LastfmFingerprint: Fix empty name exception (bgo#648168, LP: #765420)
  + Lirc: Drop liblirc_client.so moduleref (LP: #773686)
  + LiveRadio: Re-enable ShoutCast with request structure from
    RadioStationFetcher
  + Lyrics: Always update pane title when track changes (bgo#647108)
  + RadioStationFetcher: Updated the shoutcast plugin to fix the IP address
  + ZeitgeistDataprovider: Register dataprovider in DataSource
    Registry (LP: #691842)
  + ZeitgeistDataprovider: Differenciate between ScheduledActivity and
    UserActivity (LP: #748120)
* [2eab2a8] Drop useless libtool and a files from binaries (Closes: #621270)

Show diffs side-by-side

added added

removed removed

Lines of Context:
69
69
        public string NextCode ()
70
70
        {
71
71
            string code;
72
 
            if (lirc_nextcode (out code) == 0)
 
72
            if (lirc_glue_nextcode (out code) == 0)
73
73
                return (code);
74
74
            else
75
75
                return (null);
91
91
 
92
92
        public bool Connect() {
93
93
            if(!is_connected) {
94
 
                if (lirc_init (program_name, 1) == -1) {
95
 
                    Log.Warning ("lirc-sharp: lirc_init() failed");
 
94
                if (lirc_glue_init (program_name, 1) == -1) {
 
95
                    Log.Warning ("lirc-sharp: lirc_glue_init() failed");
96
96
                    this.ErrorValue = -2;
97
97
                    return(false);
98
98
                }
112
112
            if(is_connected) {
113
113
                Log.Debug ("lirc-sharp: Disconnecting LIRC connection...");
114
114
                lirc_glue_freeconfig ();
115
 
                lirc_deinit ();
 
115
                lirc_glue_deinit ();
116
116
                ErrorValue = -3;
117
117
                Log.Debug ("LIRC connection disconnected");
118
118
                is_connected = false;
150
150
 
151
151
    /* .......................lirc_client bindings.................................................*/
152
152
 
153
 
    [DllImport("lirc_client")]
154
 
    private extern static int lirc_init(string prog, int verbose);
155
 
 
156
 
    [DllImport("lirc_client")]
157
 
    private extern static int lirc_deinit();
158
 
 
159
 
    [DllImport("lirc_client")]
160
 
    private extern static int lirc_nextcode(out string code);
161
 
 
162
 
    /*[DllImport("lirc_client")]
163
 
    private extern static int lirc_readconfig(string file, out Config config, string check);
164
 
 
165
 
    [DllImport("lirc_client")]
166
 
    private extern static int lirc_freeconfig(out Config config);
167
 
 
168
 
    [DllImport("lirc_client")]
169
 
    private extern static int lirc_code2char(out Config config, string code, out string str);*/
 
153
    [DllImport("liblircglue")]
 
154
    private extern static int lirc_glue_init(string prog, int verbose);
 
155
 
 
156
    [DllImport("liblircglue")]
 
157
    private extern static int lirc_glue_deinit();
 
158
 
 
159
    [DllImport("liblircglue")]
 
160
    private extern static int lirc_glue_nextcode(out string code);
 
161
 
 
162
    /*[DllImport("liblircglue")]
 
163
    private extern static int lirc_glue_readconfig(string file, out Config config, string check);
 
164
 
 
165
    [DllImport("liblircglue")]
 
166
    private extern static int lirc_glue_freeconfig(out Config config);
 
167
 
 
168
    [DllImport("liblircglue")]
 
169
    private extern static int lirc_glue_code2char(out Config config, string code, out string str);*/
170
170
 
171
171
 
172
172
    /* someone write bindings for client daemon functions?  check out lirc_client.h */