diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2020-09-22 09:43:48 -0700 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2020-09-22 17:57:03 -0700 |
commit | f342efd080678a4c8db1c1e25296923176e821f6 (patch) | |
tree | e381f1ad2611e2b83c6acfc130d901e104371354 /mesonbuild/modules/qt.py | |
parent | 3b292a04b8797bb75f1f597dadb17d8342f9fb11 (diff) | |
download | meson-f342efd080678a4c8db1c1e25296923176e821f6.zip meson-f342efd080678a4c8db1c1e25296923176e821f6.tar.gz meson-f342efd080678a4c8db1c1e25296923176e821f6.tar.bz2 |
pylint: turn on bad-indentation error
and fix all of the bad indentation
Diffstat (limited to 'mesonbuild/modules/qt.py')
-rw-r--r-- | mesonbuild/modules/qt.py | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/mesonbuild/modules/qt.py b/mesonbuild/modules/qt.py index c7a1c46..32ff6af 100644 --- a/mesonbuild/modules/qt.py +++ b/mesonbuild/modules/qt.py @@ -87,29 +87,29 @@ class QtBaseModule(ExtensionModule): rcc_dirname, nodes = self.qrc_nodes(state, rcc_file) result = [] for resource_path in nodes: - # We need to guess if the pointed resource is: - # a) in build directory -> implies a generated file - # b) in source directory - # c) somewhere else external dependency file to bundle - # - # Also from qrc documentation: relative path are always from qrc file - # So relative path must always be computed from qrc file ! - if os.path.isabs(resource_path): - # a) - if resource_path.startswith(os.path.abspath(state.environment.build_dir)): - resource_relpath = os.path.relpath(resource_path, state.environment.build_dir) - result.append(File(is_built=True, subdir='', fname=resource_relpath)) - # either b) or c) - else: - result.append(File(is_built=False, subdir=state.subdir, fname=resource_path)) - else: - path_from_rcc = os.path.normpath(os.path.join(rcc_dirname, resource_path)) - # a) - if path_from_rcc.startswith(state.environment.build_dir): - result.append(File(is_built=True, subdir=state.subdir, fname=resource_path)) - # b) - else: - result.append(File(is_built=False, subdir=state.subdir, fname=path_from_rcc)) + # We need to guess if the pointed resource is: + # a) in build directory -> implies a generated file + # b) in source directory + # c) somewhere else external dependency file to bundle + # + # Also from qrc documentation: relative path are always from qrc file + # So relative path must always be computed from qrc file ! + if os.path.isabs(resource_path): + # a) + if resource_path.startswith(os.path.abspath(state.environment.build_dir)): + resource_relpath = os.path.relpath(resource_path, state.environment.build_dir) + result.append(File(is_built=True, subdir='', fname=resource_relpath)) + # either b) or c) + else: + result.append(File(is_built=False, subdir=state.subdir, fname=resource_path)) + else: + path_from_rcc = os.path.normpath(os.path.join(rcc_dirname, resource_path)) + # a) + if path_from_rcc.startswith(state.environment.build_dir): + result.append(File(is_built=True, subdir=state.subdir, fname=resource_path)) + # b) + else: + result.append(File(is_built=False, subdir=state.subdir, fname=path_from_rcc)) return result @noPosargs |