示例#1
0
 def _do_fetch(self, title, artist):
     sr = lyricwiki.get_lyrics(artist, title)
     if sr is None:
         sr = []
     else:
         sr = [sr]
     sr = map(lambda x: u"%s \nSource: lyrics.wikia.com" % x, sr)
     return sr
示例#2
0
 def _do_fetch(self, title, artist):
     sr = lyricwiki.get_lyrics(artist, title)
     if sr is None:
         sr = []
     else:
         sr = [sr]
     sr = map(lambda x: u"%s \nSource: lyrics.wikia.com" % x, sr)
     return sr
示例#3
0
文件: lyrics.py 项目: GunioRobot/ccx2
  def from_url(self):
    self.lyrics.set_info("fetching lyrics...")

    lyrics = lyricwiki.get_lyrics(self.url)

    if self.abort:
      return

    if lyrics:
      self.save_lyrics(lyrics)
      self.lyrics.set_lyrics(lyrics)
    else:
      self.lyrics.set_info("some kind of error occurred while fetching the lyrics, try again!")
示例#4
0
文件: lyrics.py 项目: GunioRobot/ccx2
    def from_url(self):
        self.lyrics.set_info("fetching lyrics...")

        lyrics = lyricwiki.get_lyrics(self.url)

        if self.abort:
            return

        if lyrics:
            self.save_lyrics(lyrics)
            self.lyrics.set_lyrics(lyrics)
        else:
            self.lyrics.set_info(
                "some kind of error occurred while fetching the lyrics, try again!"
            )