[Rhythmbox-devel] entry-changed signal returns GLib.Array instead of GObject.ValueArray
- From: "Mendhak (RBM)" <rbmailinglist mendhak com>
- To: rhythmbox-devel gnome org
- Subject: [Rhythmbox-devel] entry-changed signal returns GLib.Array instead of GObject.ValueArray
- Date: Thu, 27 Jun 2013 22:46:11 +0100
Hi, I had posted this earlier but I'm afraid the thread might have been missed and wasn't worded well enough.
I have a plugin, and the entry-changed event is passing a GLib.Array, but there seem to be no bindings I can work with in Python. Looking at the object I get in an entry-changed event, I don't know how to work with it to get the RhythmDbEntryChange objects out. I think this doesn't match with the documentation of event-changed.
Docu:
https://developer.gnome.org/rhythmbox/unstable/RhythmDB.html#RhythmDB-entry-changed
I tried iterating over changes, but I get
TypeError: 'Array' object is not iterable
I tried accessing an item directly, but I get
TypeError: 'Array' object is not iterable
The .len property gives the length of the array and the .data property gives me some garbled unicode or control characters that I can't print to console.
I guess the documentation is no longer correct but I don't know how to work with the object being passed in entry-changed. Unfortunately this is breaking my plugin and I can't proceed without using the entry-changed event.
Here is a sample of the code that used to work in the entry-changed event.
for i in range(0,changes.n_values):
change = changes.get_nth(i)
I am running Ubuntu 13.04 and Rhythmbox 2.98. Any help would be appreciated,
Thanks
Mendhak
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]