Files
PDFReaderLite/pdfreaderlite/resources.py
T

18 lines
448 B
Python
Raw Normal View History

2026-06-29 14:58:36 +08:00
from __future__ import annotations
import sys
from pathlib import Path
def resource_path(relative_path: str) -> Path:
base_path = Path(getattr(sys, "_MEIPASS", Path(__file__).resolve().parents[1]))
return base_path / relative_path
def software_icon_path() -> Path:
2026-06-29 15:54:43 +08:00
return resource_path("resources/icons/icon_software_multisize.ico")
2026-06-29 14:58:36 +08:00
def pdf_icon_path() -> Path:
2026-06-29 15:54:43 +08:00
return resource_path("resources/icons/icon_pdf_multisize.ico")