Jaime van Kessel
6e5b0bb609
Fix the filtering of materials based on exclude_materials
...
CURA-6600
2019-08-07 17:03:41 +02:00
Ghostkeeper
accc4ccd21
Only remove excluded materials that were added
...
Contributes to issue CURA-6600.
2019-08-07 09:50:53 +02:00
Ghostkeeper
8e49991087
Resolve circular imports
...
Some of these are only used for the type checks.
Contributes to issue CURA-6600.
2019-08-06 17:04:29 +02:00
Ghostkeeper
b05784e607
Remove subprofiles from intent nodes
...
As the documentation says, it has no subprofiles any more.
Contributes to issue CURA-6600.
2019-08-06 16:49:06 +02:00
Ghostkeeper
a0d3cb6742
Make QualityNode part of our normal tree structure
...
It now constructs itself and its contents automatically. No need for a QualityManager to keep it up to date any more.
Contributes to issue CURA-6600.
2019-08-06 16:46:28 +02:00
Ghostkeeper
8ec1c31b58
Don't make parent a common property
...
Instead we use properly-typed and appropriately-named variables in each of the sub classes.
Contributes to issue CURA-6600.
2019-08-06 16:31:57 +02:00
Ghostkeeper
d3dc36c187
Find quality nodes as subnodes of material nodes
...
Similar to the materials and variants.
Contributes to issue CURA-6600.
2019-08-06 16:19:30 +02:00
Ghostkeeper
24346fc8e3
Don't add materials forbidden by the printer definition
...
Contributes to issue CURA-6600.
2019-08-06 15:21:52 +02:00
Ghostkeeper
3ef0b4292d
Only add variants that fit on my machine
...
Contributes to issue CURA-6600.
2019-08-06 15:15:02 +02:00
Ghostkeeper
bc3300baa8
Assume that the tree is always constructed after metadata has been loaded
...
Safe assumption, since the tree can only start constructing after the stacks are loaded.
Contributes to issue CURA-6600.
2019-08-06 15:13:29 +02:00
Ghostkeeper
b46d4eb2b5
Have variant nodes build their own children
...
When a variant and a variant love each other...
Contributes to issue CURA-6600.
2019-08-06 15:11:16 +02:00
Ghostkeeper
65b1a43e88
Load tree when all metadata has been loaded
...
This should build up the tree initially.
Contributes to issue CURA-6600.
2019-08-06 09:16:41 +02:00
Ghostkeeper
2565be01f3
Add variants as they get added to the registry
...
Contributes to issue CURA-6600.
2019-08-06 08:58:34 +02:00
Ghostkeeper
e84a75094a
Add a MachineNode once a definition for it gets loaded
...
This means that we've added this machine. We need to pre-load all of the containers for that printer then.
Contributes to issue CURA-6600.
2019-08-05 17:49:21 +02:00
Ghostkeeper
9fda7bd0b9
Rework container tree structure
...
This sets up a few new classes, subclasses of ContainerNode.
This is intended to simplify the current structure in the QualityManager.
Contributes to issue CURA-6600.
2019-08-05 17:39:19 +02:00
ChrisTerBeke
1fa5628cb2
Rename output device to prevent inheritance naming confusion
2019-08-02 15:16:08 +02:00
ChrisTerBeke
92d07ddb71
Merge branch 'master' into CS-234_network_plugin_code_quality
2019-08-02 12:44:56 +02:00
Lipu Fei
c841382bbd
Add more info in exceptions
2019-08-02 11:12:16 +02:00
Ghostkeeper
b3912fb930
Merge branch '4.2'
2019-07-31 10:43:17 +02:00
Jaime van Kessel
4b956953a6
Fix incorect error checking
...
We don't need to check the global stack for errors, as the correct values are already checked by looking at the extruder stacks
2019-07-31 10:24:31 +02:00
ChrisTerBeke
1aa70748af
Consistent naming, some bug fixes
2019-07-29 17:24:10 +02:00
ChrisTerBeke
ddd282eef3
Remove absolute plugin imports, some fixes
2019-07-29 16:11:01 +02:00
Jaime van Kessel
9ceb9ce18b
Fix typing issues
...
They were caused by upgrading to a higher mypy version, which found more mistakes
2019-07-23 12:58:46 +02:00
Lipu Fei
4e0b9d7b78
Fix typing
...
CURA-6597
2019-07-09 13:02:01 +02:00
Lipu Fei
8863516aa4
Rename function name and fix tests
...
CURA-6597
2019-07-09 12:53:44 +02:00
Lipu Fei
659a276f65
Rename signal
...
CURA-6597
2019-07-09 11:29:27 +02:00
Ghostkeeper
e2fd90506a
Include intent profiles from the default intents
...
If we have the default intent category, list all quality types available.
Contributes to issue CURA-6597.
2019-07-09 10:56:21 +02:00
Ghostkeeper
86750c0446
Don't continue after returning empty list
...
Oops. Shouldn't have pushed...
Contributes to issue CURA-6597.
2019-07-09 10:54:47 +02:00
Ghostkeeper
07c5c4d9f0
Return empty model if there is no printer added yet
...
Contributes to issue CURA-6597.
2019-07-09 10:26:49 +02:00
Ghostkeeper
45cb34c3e4
Refresh list of intents upon changing category
...
The category is changed after constructing by the QML code in order to set its property.
This is now updating twice: Once for the default category and once for the final one set by QML. This is a bit inefficient. But make it work before optimising it!
Contributes to issue CURA-6597.
2019-07-05 11:19:16 +02:00
Ghostkeeper
6e373e02c0
Update through self.setItems rather than super().update
...
Because super().update doesn't exist in this case. Stupid.
Contributes to issue CURA-6597.
2019-07-04 12:36:14 +02:00
Ghostkeeper
0047874f03
Get translation from list of keys rather than items
...
Because the category is not in a list of tuples. It's just the key of the dict.
Contributes to issue CURA-6597.
2019-07-04 12:35:11 +02:00
Ghostkeeper
a6e3828eaa
Efficiency: Don't update model if adding different container types
...
In fact we might want to delay updating until after the program has started up.
Contributes to issue CURA-6597.
2019-07-04 12:33:50 +02:00
Ghostkeeper
cf68157508
Fix updating upon containers or configuration changing
...
Copy-paste mistake...
Contributes to issue CURA-6597.
2019-07-04 12:29:02 +02:00
Ghostkeeper
bd2237dc45
Update intent categories upon adding containers or changing configuration
...
Also upon start-up.
Contributes to issue CURA-6597.
2019-07-04 11:31:59 +02:00
Ghostkeeper
6ba70f3425
Rewrite IntentModel to return quality types rather than actual profiles
...
We don't want the profiles, because that'd be specific to one extruder. We want the quality types and intent categories as tuples again.
Contributes to issue CURA-6597.
2019-07-04 11:04:44 +02:00
Ghostkeeper
3f29bce263
List intents per category
...
This is the naive one. We want to list the default intents multiple times, once for every quality level.
Contributes to issue CURA-6597.
2019-07-03 16:51:47 +02:00
Remco Burema
6b918dbd1d
Fix typing in IntentCategoryModel.
2019-06-28 12:04:04 +02:00
Ghostkeeper
f339686c49
Implement category model
...
Not just pseudocode. However this code is not yet tested.
Contributes to issue CURA-6091.
2019-06-21 12:45:44 +02:00
Ghostkeeper
28e2569c86
Implement complete code for currentAvailableIntents
...
Slightly more complex than the original pseudocode was indicating: It needs to filter on the available quality types first in order to only show the quality types that can be printed with all extruders, but still show the union of all intents for those quality types.
Contributes to issue CURA-6091.
2019-06-20 14:48:18 +02:00
Ghostkeeper
fa65875824
Add psuedocode/boilerplate for intent manager
...
This won't run. Don't try to import this class yet. It's outlining what we need to implement to get intents per stack.
It does no form of caching at this point. Build first, optimise later, right.
Contributes to issue CURA-6091.
2019-06-19 14:29:19 +02:00
Ghostkeeper
5ab1881a21
Merge branch 'master' into feature_intent
...
Conflicts:
plugins/VersionUpgrade/VersionUpgrade41to42/VersionUpgrade41to42.py -> There is a new version upgrade in master, so the old one is sort of obsolete. We may have to move this part to a new version upgrade for 4.3.
plugins/VersionUpgrade/VersionUpgrade41to42/__init__.py
2019-06-19 13:10:36 +02:00
Jaime van Kessel
a98f88e6a3
Also move _getMachineTypeNameFromId to DiscoveredPrintersModel
...
As this is only used by that model, there is no point in keeping it in the machine manager
2019-06-07 15:04:19 +02:00
Jaime van Kessel
5eee3fc368
Move hasHumanReadableMachienTypeName to discovered printers
2019-06-07 15:01:30 +02:00
Jaime van Kessel
05a5f66856
Added few more deprecation warnings for functions that bloat the machine manager
2019-06-07 14:57:32 +02:00
Jaime van Kessel
35ec70a3cf
Add a selector for the intent profile
...
CURA-6534
2019-06-05 11:13:32 +02:00
Jaime van Kessel
2d8c19203e
Expose intent model to QML
...
CURA-6534
2019-06-05 09:57:42 +02:00
Jaime van Kessel
2e7f8b066a
Ensure that the intent model gets populated
...
CURA-6534
2019-06-04 17:32:11 +02:00
Jaime van Kessel
266cf52cbc
Add stub for the IntentModel
...
CURA-6534
2019-06-04 17:24:34 +02:00
Lipu Fei
2054413952
Add handling for ValidatorState.Invalid
...
CURA-6497
ValidatorState.Invalid is set if a string setting has allow_empty =
False and its value is empty.
2019-05-09 12:07:16 +02:00