修复action的对钩问题
This commit is contained in:
parent
6ab330418e
commit
911cca5373
|
@ -42,6 +42,7 @@ urlSourcesList = [
|
|||
"http://gfdgdxi.free.idcfengye.com/uengine-runner-list/auto/", # 备用源 3
|
||||
"http://127.0.0.1/uengine-runner-list/auto/" # 本地测试源
|
||||
]
|
||||
urlSourcesIndex = 0
|
||||
urlSources = urlSourcesList[0]
|
||||
lists = []
|
||||
|
||||
|
@ -522,6 +523,7 @@ def readtxt(path):
|
|||
|
||||
def ChangeSources():
|
||||
global urlSources
|
||||
global urlSourcesIndex
|
||||
sources = [ui.actionGitlink, ui.actionGitee, ui.actionGithub, ui.action_IPv6, ui.action_2, ui.action_3, ui.action]
|
||||
for i in range(0, len(sources)):
|
||||
if sources[i].isChecked():
|
||||
|
@ -535,7 +537,9 @@ def ChangeSources():
|
|||
for i in lists:
|
||||
nmodel.appendRow(QtGui.QStandardItem(i[0]))
|
||||
ui.searchList.setModel(nmodel)
|
||||
urlSourcesIndex = i
|
||||
except:
|
||||
[ui.actionGitlink, ui.actionGitee, ui.actionGithub, ui.action_IPv6, ui.action_2, ui.action_3, ui.action][urlSourcesIndex].setChecked(True)
|
||||
traceback.print_exc()
|
||||
QtWidgets.QMessageBox.critical(window, "提示", "无法连接服务器")
|
||||
break
|
||||
|
|
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue