Пример #1
0
 def change_to_simi(self):
     PlaylistItem.de_active_all()
     if self.current_mode == 1:
         FmMode.exit_()
     if self.current_mode == 2:
         ControllerApi.notify_widget.show_message("提示", "你正处于单曲电台模式")
         return
     self.current_mode = 2
     ControllerApi.player.change_player_mode_to_other()
     SimiSongsMode.load_()
Пример #2
0
 def change_to_simi(self):
     PlaylistItem.de_active_all()
     if self.current_mode == 1:
         FmMode.exit_()
     elif self.current_mode == 2:
         ControllerApi.notify_widget.show_message("提示", "你正处于单曲电台模式")
         return
     self.current_mode = 2
     ControllerApi.player.change_player_mode_to_other()
     SimiSongsMode.load_()
Пример #3
0
 def search_music(self):
     text = self.ui.SEARCH_BOX.text()
     if text != '':
         self.ui.STATUS_BAR.showMessage(u'正在搜索: ' + text)
         songs = self.api.search(text)
         if not self.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         self.ui.WEBVIEW.load_search_result(songs)
         self.state['current_pid'] = 0
         length = len(songs)
         if length != 0:
             self.ui.STATUS_BAR.showMessage(u'搜索到 ' + str(length) + u' 首 ' + text + u' 相关歌曲', 5000)
             return
         else:
             self.ui.STATUS_BAR.showMessage(u'很抱歉,没有找到相关歌曲', 5000)
             return
Пример #4
0
 def _search_music(self):
     text = ViewOp.ui.SEARCH_BOX.text()
     if text != '':
         ViewOp.ui.STATUS_BAR.showMessage(u'正在搜索: ' + text)
         songs = ControllerApi.api.search(text)
         if not ControllerApi.api.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         ViewOp.ui.WEBVIEW.load_search_result(songs)
         ControllerApi.state['current_pid'] = 0
         length = len(songs)
         if length != 0:
             ViewOp.ui.STATUS_BAR.showMessage(u'O(∩_∩)O,搜索到 ' + str(length) + u' 首 ' + text + u' 相关歌曲', 5000)
             return
         else:
             ViewOp.ui.STATUS_BAR.showMessage(u'Oops,没有找到相关歌曲', 5000)
             return
Пример #5
0
 def search_music(self):
     text = self.ui.SEARCH_BOX.text()
     if text != "":
         self.ui.STATUS_BAR.showMessage(u"正在搜索: " + text)
         songs = self.api.search(text)
         if not self.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         self.ui.WEBVIEW.load_search_result(songs)
         self.state["current_pid"] = 0
         length = len(songs)
         if length != 0:
             self.ui.STATUS_BAR.showMessage(u"搜索到 " + str(length) + u" 首 " + text + u" 相关歌曲", 5000)
             return
         else:
             self.ui.STATUS_BAR.showMessage(u"很抱歉,没有找到相关歌曲", 5000)
             return
Пример #6
0
 def search_music(self):
     text = self.ui.top_widget.search_edit.text()
     if text != '':
         self.status.showMessage(u'正在搜索: ' + text)
         songs = self.api.search(text)
         if not self.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         self.webview.load_search_result(songs)
         self.state['current_pid'] = 0
         length = len(songs)
         if length != 0:
             self.status.showMessage(u'搜索到 ' + str(length) + u' 首 ' + text + u' 相关歌曲', 5000)
             return
         else:
             self.ui.status.showMessage(u'很抱歉,没有找到相关歌曲', 5000)
             return
Пример #7
0
 def search_music(self):
     text = self.ui.top_widget.search_edit.text()
     if text != '':
         self.status.showMessage(u'正在搜索: ' + text)
         songs = self.api.search(text)
         if not self.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         self.webview.load_search_result(songs)
         self.state['current_pid'] = 0
         length = len(songs)
         if length != 0:
             self.status.showMessage(u'搜索到 ' + str(length) + u' 首 ' + text + u' 相关歌曲', 5000)
             return
         else:
             self.ui.status.showMessage(u'很抱歉,没有找到相关歌曲', 5000)
             return
Пример #8
0
 def search_music(self):
     text = self.ui.top_widget.search_edit.text()
     if text != "":
         self.status.showMessage(u"正在搜索: " + text)
         songs = self.api.search(text)
         if not self.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         self.webview.load_search_result(songs)
         self.state["current_pid"] = 0
         length = len(songs)
         if length != 0:
             self.status.showMessage(u"搜索到 " + str(length) + u" 首 " + text + u" 相关歌曲", 5000)
             return
         else:
             self.ui.status.showMessage(u"很抱歉,没有找到相关歌曲", 5000)
             return
Пример #9
0
 def search_music(self):
     text = self.ui.SEARCH_BOX.text()
     if text != '':
         self.ui.STATUS_BAR.showMessage(u'正在搜索: ' + text)
         songs = self.api.search(text)
         if not self.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         self.ui.WEBVIEW.load_search_result(songs)
         self.state['current_pid'] = 0
         length = len(songs)
         if length != 0:
             self.ui.STATUS_BAR.showMessage(
                 u'搜索到 ' + str(length) + u' 首 ' + text + u' 相关歌曲', 5000)
             return
         else:
             self.ui.STATUS_BAR.showMessage(u'很抱歉,没有找到相关歌曲', 5000)
             return
Пример #10
0
 def _search_music(self):
     text = ViewOp.ui.SEARCH_BOX.text()
     if text != '':
         ViewOp.ui.STATUS_BAR.showMessage(u'正在搜索: ' + text)
         songs = ControllerApi.api.search(text)
         if not ControllerApi.api.is_response_ok(songs):
             return
         PlaylistItem.de_active_all()
         ViewOp.ui.WEBVIEW.load_search_result(songs)
         ControllerApi.state['current_pid'] = 0
         length = len(songs)
         if length != 0:
             ViewOp.ui.STATUS_BAR.showMessage(
                 u'O(∩_∩)O,搜索到 ' + str(length) + u' 首 ' + text + u' 相关歌曲',
                 5000)
             return
         else:
             ViewOp.ui.STATUS_BAR.showMessage(u'Oops,没有找到相关歌曲', 5000)
             return