-
Notifications
You must be signed in to change notification settings - Fork 17
create dot for collapsed node in trainrunSectionViewObject #669
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: mrd/new-nodes-management-system
Are you sure you want to change the base?
create dot for collapsed node in trainrunSectionViewObject #669
Conversation
Signed-off-by: Louis Greiner <[email protected]>
src/app/view/editor-main-view/data-views/trainrunSectionViewObject.ts
Outdated
Show resolved
Hide resolved
src/app/view/editor-main-view/data-views/trainrunsections.view.ts
Outdated
Show resolved
Hide resolved
|
I wonder if we really need this PR given #661 is almost the same code. Maybe adding a method to get the number of intermediate nodes is worthwhile, but otherwise the code seems pretty similar. Oh, I just realized we don't want to count non-stop intermediate nodes, even if they're collapsed? In other words, we only want to draw a small disc for stops? |
|
These changes can be added to #661 of course. We want to draw a dot (small circle) for each intermediate stop collasped node. Intermediate non-stop nodes are not shown (= "ghost"). |
|
This PR uses
|
|
|
||
| getCollapsedIntermediateStopCount(): number { | ||
| // Count collapsed source nodes from all trainrun sections except the first one | ||
| return this.trainrunSections.length - 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should check if the nodes are actual stops
Create a visual Dot for each collapsed node in a trainrun sections chain (
trainrunSectionViewObject)Code picked from mrd/demo-intermediate-collapsed-dots
Might conflict a bit with #661