Make qrc path aliases the same as filesystem ones
This commit is contained in:
@@ -23,11 +23,11 @@ int main(int argc, char *argv[]) {
|
||||
objectContext->setContextProperty("debugMode", false);
|
||||
#endif
|
||||
|
||||
QFileInfo qrcPath(":/qml/Window.qml");
|
||||
QFileInfo qrcPath(":src/qml/Window.qml");
|
||||
|
||||
QQmlComponent component(
|
||||
&engine,
|
||||
qrcPath.exists() ? "qrc:/qml/Window.qml" : "src/qml/Window.qml"
|
||||
qrcPath.exists() ? "qrc:/src/qml/Window.qml" : "src/qml/Window.qml"
|
||||
);
|
||||
component.create(objectContext);
|
||||
|
||||
|
@@ -163,7 +163,7 @@ class Theme(ConfigFile):
|
||||
|
||||
|
||||
async def default_data(self) -> str:
|
||||
async with aiofiles.open("src/themes/Default.qpl", "r") as file:
|
||||
async with aiofiles.open("src/themes/Default.qpl") as file:
|
||||
return await file.read()
|
||||
|
||||
|
||||
|
@@ -53,7 +53,7 @@ Python {
|
||||
}
|
||||
|
||||
addImportPath("src")
|
||||
addImportPath("qrc:/")
|
||||
addImportPath("qrc:/src")
|
||||
importNames("python", ["APP"], () => {
|
||||
loadSettings(() => {
|
||||
callCoro("saved_accounts.any_saved", [], any => {
|
||||
|
Reference in New Issue
Block a user