mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Adding a field of the build type to the spashscreen.
For example, if the community distributes Cura in a different way, they can set CURA_BUILDTYPE via 'cmake -DCURA_BUILDTYPE=' and whenever Cura is launched " (PPA)" will be appended. Of course, this could be done by appending " (PPA)" to CURA_VERSION, but in case of my Ubuntu/Debian packaging it will only need one modification in debian/changelog to change the version. During build (debian/rules) this version will be read from debian/changelog. Changing the version number across different files, is a waste of time. Finally, we can use that field in the future to indicate debug or other other special builds.
This commit is contained in:
parent
15f84c758b
commit
c62ab6e937
4 changed files with 8 additions and 2 deletions
|
@ -61,9 +61,10 @@ if platform.system() == "Linux": # Needed for platform.linux_distribution, which
|
|||
ctypes.CDLL(find_library('GL'), ctypes.RTLD_GLOBAL)
|
||||
|
||||
try:
|
||||
from cura.CuraVersion import CuraVersion
|
||||
from cura.CuraVersion import CuraVersion, CuraBuildType
|
||||
except ImportError:
|
||||
CuraVersion = "master" # [CodeStyle: Reflecting imported value]
|
||||
CuraBuildType = ""
|
||||
|
||||
|
||||
class CuraApplication(QtApplication):
|
||||
|
@ -89,7 +90,7 @@ class CuraApplication(QtApplication):
|
|||
# Need to do this before ContainerRegistry tries to load the machines
|
||||
SettingDefinition.addSupportedProperty("global_only", DefinitionPropertyType.Function, default = False)
|
||||
|
||||
super().__init__(name = "cura", version = CuraVersion)
|
||||
super().__init__(name = "cura", version = CuraVersion, build_type = CuraBuildType)
|
||||
|
||||
self.setWindowIcon(QIcon(Resources.getPath(Resources.Images, "cura-icon.png")))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue