- Removed unnecesary threading from music_player (Possibly causes crashes now)

This commit is contained in:
noisymime 2008-05-06 12:34:47 +00:00
parent d60e21c9eb
commit 8e7c5c9d95
2 changed files with 7 additions and 5 deletions

View File

@ -74,6 +74,7 @@ class song:
loader = gtk.gdk.PixbufLoader()
loader.write(data)
loader.close()
if self.music_player.glossMgr.debug: print "Music_Player:Image successfully written to pixbuf loader: " + str(img.mimeType)
return loader.get_pixbuf()
except gobject.GError:
if self.music_player.glossMgr.debug:

View File

@ -157,10 +157,11 @@ class Module:
#Just a little test code
self.artistImageRow.objectLibrary[0].unpause_threads()
artist = self.artistImageRow.get_current_object()
thread = threading.Thread(target=self.backend.get_albums_by_artistID, args=(artist.artistID,))
thread.start()
#thread.start_new_thread(self.backend.get_albums_by_artistID, (artist.artistID,))
self.conn_id = self.backend.connect("query-complete", self.update_for_albums, artist)
self.backend.get_albums_by_artistID(artist.artistID)
#thread = threading.Thread(target=self.backend.get_albums_by_artistID, args=(artist.artistID,))
#thread.start()
def update_for_albums(self, data, artist = None):
if not artist == self.artistImageRow.get_current_object(): return
@ -169,14 +170,14 @@ class Module:
self.backend.disconnect(self.conn_id)
self.current_albums = self.backend.get_albums_by_artistID(artist.artistID)
clutter.threads_enter()
#clutter.threads_enter()
self.list1.clear()
for album in self.current_albums:
tmpItem = self.list1.add_item(album.name)
tmpItem.connect("selected", self.process_songlist_from_album, album)
self.list1.display()
self.update_main_img()
clutter.threads_leave()
#clutter.threads_leave()
def update_main_img(self, data = None):
#clutter.threads_enter()