• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

moosetechnology / MooseIDE / 21333948876

25 Jan 2026 02:11PM UTC coverage: 65.304% (-0.03%) from 65.33%
21333948876

Pull #1568

github

web-flow
Merge ebe44d314 into 5cb3a0d17
Pull Request #1568: make presenter initialization standard for all MiAbstractVisualizationBrowsers

22 of 22 new or added lines in 4 files covered. (100.0%)

2 existing lines in 2 files now uncovered.

21781 of 33353 relevant lines covered (65.3%)

1.31 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

57.73
/src/MooseIDE-DistributionMap/MiDistributionMapBrowser.class.st
1
"
2
I am a browser that displays a distribution map.
3
Accepted entities: any MooseEntity.
4

5
Controls:
6

7
* Mouse over to highlight common inner boxes
8
* Mouse click to keep the highlight
9
* right click over a box, to use the menu
10
* right click over the view to use the general menu
11
* command+click to use the last tag.
12

13
* Mouse left to drag
14
* Arrrow keys to move the visualization around
15
* Scrolls bars to change the view's position
16
* M to collapse or expand the window
17
* I to zoom in
18
* O to zoom out
19
* Moouse Wheel to zoom in/out
20
* S to search entities by their name (several search can be applied)
21
* R to clear all searches
22
"
23
Class {
24
        #name : 'MiDistributionMapBrowser',
25
        #superclass : 'MiAbstractVisualizationBrowser',
26
        #category : 'MooseIDE-DistributionMap',
27
        #package : 'MooseIDE-DistributionMap'
28
}
29

30
{ #category : 'accessing' }
31
MiDistributionMapBrowser class >> mapClass [
2✔
32

2✔
33
        ^ MiDistributionMapVisualization
2✔
34
]
2✔
35

36
{ #category : 'world menu' }
37
MiDistributionMapBrowser class >> menuCommandOn: aBuilder [
×
38

×
39
        <worldMenu>
×
40
        <miBrowsersMenu>
×
41
        ^ self buildMenuItemIn: aBuilder
×
42
]
×
43

44
{ #category : 'world menu' }
45
MiDistributionMapBrowser class >> menuItem [
×
46

×
47
        ^ #DMBrowser
×
48
]
×
49

50
{ #category : 'world menu' }
51
MiDistributionMapBrowser class >> menuPriority [
×
52

×
53
        ^ self menuVisualizationToolsPriority + 5
×
54
]
×
55

56
{ #category : 'instance creation' }
57
MiDistributionMapBrowser class >> newModel [
2✔
58

2✔
59
        ^ MiDistributionMapModel new
2✔
60
]
2✔
61

62
{ #category : 'instance creation' }
63
MiDistributionMapBrowser class >> open [
×
64

×
65
        <script>
×
66
        ^ super open
×
67
]
×
68

69
{ #category : 'specs' }
70
MiDistributionMapBrowser class >> preferredExtent [
2✔
71

2✔
72
        ^ 850 @ 520
2✔
73
]
2✔
74

75
{ #category : 'specs' }
76
MiDistributionMapBrowser class >> title [
2✔
77

2✔
78
        ^ 'Distribution map'
2✔
79
]
2✔
80

81
{ #category : 'adding' }
82
MiDistributionMapBrowser >> addDynamicTags: aCollection [
×
83

×
84
        aCollection do: [ :dt | self specModel addDynamicTag: dt ].
×
85
        "settings refreshTagList"
×
86
]
×
87

88
{ #category : 'actions' }
89
MiDistributionMapBrowser >> availableQueries [
×
90

×
91
        ^ (self application itemsFor: FQAbstractQuery) asOrderedCollection 
×
92
                  select: [ :q | q isValid ]
×
93
]
×
94

95
{ #category : 'window control' }
96
MiDistributionMapBrowser >> browserClosed [
2✔
97

2✔
98
        super browserClosed.
2✔
99
        application unregisterConsumer: self
2✔
100
]
2✔
101

102
{ #category : 'testing' }
103
MiDistributionMapBrowser >> canFollowEntity: aCollection [
2✔
104

2✔
105
        | uniqType confirm |
2✔
106
        aCollection isCollection ifFalse: [ ^ false ].
2✔
107

2✔
108
        "for example, this allows to open on an empty collection
2✔
109
         (to propagate entities later)"
2✔
110
        aCollection ifEmpty: [ ^ true ].
2✔
111

2✔
112
        aCollection size > self specModel tooManyEntities ifTrue: [
2✔
113
                        confirm := UIManager default confirm:
2✔
114
                                           'DistributionMap uses an algorithm in O^2.
2✔
115
Propagating many entities to it will result in lengthy computation.
2✔
116
Are you sure you want to continue ?'.
2✔
117
                        confirm ifFalse: [ ^ false ] ].
2✔
118

2✔
119
        uniqType := aCollection anyOne class.
2✔
120
        (aCollection allSatisfy: [ :e | e class = uniqType ]) ifFalse: [
2✔
121
                        confirm := UIManager default confirm:
2✔
122
                                           'DistributionMap is intend to work on _one_ kind of entity (and their direct ''children'').
2✔
123
You are propagating several different kinds of entities.
2✔
124
Are you sure you want to continue ?
2✔
125
(That might result in unecessary lengthy computation)'.
2✔
126
                        confirm ifFalse: [ ^ false ] ].
2✔
127

2✔
128
        ^ true
2✔
129
]
2✔
130

131
{ #category : 'testing' }
132
MiDistributionMapBrowser >> canReceiveEntity: anEntity [
×
133

×
134
        ^ anEntity isMooseObject
×
135
]
×
136

137
{ #category : 'initialization' }
138
MiDistributionMapBrowser >> canvas [
×
139

×
140
        ^ mainPresenter canvas
×
141
]
×
142

143
{ #category : 'actions' }
144
MiDistributionMapBrowser >> followEntity: anEntity [
2✔
145

2✔
146
        super followEntity: anEntity.
2✔
147
        specModel
2✔
148
                entities: anEntity asMooseGroup;
2✔
149
                initializeSettings.
2✔
150
        self runVisualization
2✔
151
]
2✔
152

153
{ #category : 'initialization' }
UNCOV
154
MiDistributionMapBrowser >> visualization [
×
155

×
156
        ^ mainPresenter
×
157
]
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc