mirror of
https://github.com/Bao-qing/123pan.git
synced 2026-02-12 13:00:31 +08:00
cdbyid
This commit is contained in:
parent
4d402f7889
commit
aa9d54390f
7
.gitignore
vendored
7
.gitignore
vendored
|
|
@ -1,3 +1,10 @@
|
||||||
123pan_config.json
|
123pan_config.json
|
||||||
download/*
|
download/*
|
||||||
123pan.txt
|
123pan.txt
|
||||||
|
dist/*
|
||||||
|
build/*
|
||||||
|
123pan.dist/*
|
||||||
|
.idea/*
|
||||||
|
123pan.exe
|
||||||
|
123pan.spec
|
||||||
|
android.py
|
||||||
15
123pan.py
15
123pan.py
|
|
@ -860,6 +860,21 @@ class Pan123:
|
||||||
print(f"已切换到 {protocol} 协议")
|
print(f"已切换到 {protocol} 协议")
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
def cdById(self, file_id: int):
|
||||||
|
"""根据文件夹ID切换目录"""
|
||||||
|
# 重置文件页数和文件列表
|
||||||
|
self.all_file = False
|
||||||
|
self.file_page = 0
|
||||||
|
self.list = []
|
||||||
|
|
||||||
|
# 更新当前目录ID和目录列表
|
||||||
|
self.parent_file_id = file_id
|
||||||
|
self.parent_file_list.append(self.parent_file_id)
|
||||||
|
|
||||||
|
# 获取新目录内容并显示
|
||||||
|
self.get_dir()
|
||||||
|
self.show()
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
"""主交互函数"""
|
"""主交互函数"""
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user