from xiamiSingsFrames import XiamiSingsArea, XiamiSearchResultFrame from qqSingsFrames import QQSingsArea, QQSearchResultFrame # features from configMainFeatures import (ConfigWindow, ConfigHeader, ConfigNavigation, ConfigMainContent, ConfigSearchArea, ConfigSystemTray) from configNativeFeatures import ConfigNative from configNeteaseFeatures import ConfigNetEase, ConfigDetailSings from configXiamiFeatures import ConfigXiami from configQQFeatures import ConfigQQ # logger import logger logger.loggerConfig('logger/running_log.log') # 覆盖原logger变量。 logger = logging.getLogger(__name__) # 用于承载整个界面。所有窗口的父窗口,所有窗口都可以在父窗口里找到索引。 class Window(QWidget): """Window 承载整个界面。""" def __init__(self): super(Window, self).__init__() self.setObjectName('MainWindow') self.setWindowFlags(Qt.FramelessWindowHint) self.setWindowIcon(QIcon('resource/format.ico')) self.setWindowTitle("Music")
# features from configMainFeatures import (ConfigWindow, ConfigHeader, ConfigNavigation, ConfigMainContent, ConfigSearchArea, ConfigSystemTray, ConfigDetailSings) from configNativeFeatures import ConfigNative from configDownloadFrameFeatures import ConfigDownloadFrame from configNeteaseFeatures import ConfigNetEase from configXiamiFeatures import ConfigXiami from configQQFeatures import ConfigQQ from configRecommendFrameFeatures import ConfigRecommendFrame # logger import logger logger.loggerConfig('logger/running_log.log') # 覆盖原logger变量。 logger = logging.getLogger(__name__) logger.info("当前图片缓存目录: {0}".format(os.path.join(os.getcwd(), cacheFolder))) # 用于承载整个界面。所有窗口的父窗口,所有窗口都可以在父窗口里找到索引。 # 2018/03/18 # 这种嵌套虽然不会出错但有点麻烦,但又不知如何设计得更好。 # 最近在学vue,发现其与Qt有些相似,貌似有个叫vuex的可以很好得管理这些问题。 # 待学习改进。 class Window(QWidget): """Window 承载整个界面。""" def __init__(self):