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

moosetechnology / MooseIDE / 17320540290

29 Aug 2025 09:48AM UTC coverage: 66.77% (-0.05%) from 66.822%
17320540290

Pull #1387

github

web-flow
Merge fc6f7e61e into 40308058a
Pull Request #1387: adding a close button to the popover presenter of manual queries

0 of 7 new or added lines in 1 file covered. (0.0%)

13 existing lines in 2 files now uncovered.

19828 of 29696 relevant lines covered (66.77%)

1.34 hits per line

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

0.0
/src/MooseIDE-QueriesBrowser/QueryCompilerPresenter.class.st
1
"
2
I am used in the manual query condigurator presenter. I have a code presenter in which you can enter some valid query code that I will compile an return the object
3
"
4
Class {
5
        #name : 'QueryCompilerPresenter',
6
        #superclass : 'MiPresenter',
7
        #instVars : [
8
                'submitButton',
9
                'codePresenter',
10
                'configuratorPresenter',
11
                'closeButton'
12
        ],
13
        #category : 'MooseIDE-QueriesBrowser-Widgets',
14
        #package : 'MooseIDE-QueriesBrowser',
15
        #tag : 'Widgets'
16
}
17

18
{ #category : 'accessing' }
19
QueryCompilerPresenter >> code [
×
20
        ^ codePresenter text
×
21
]
×
22

23
{ #category : 'compiling' }
24
QueryCompilerPresenter >> compileQuery [
×
25

×
26
        | compiledQuery |
×
27
        compiledQuery := codePresenter
×
28
                evaluate: codePresenter text
×
29
                onCompileError: [ :e | ^ self ]
×
30
                onError: [ :e | e pass ].
×
31
        compiledQuery beChildOf: configuratorPresenter queriesBrowser rootQuery.
×
32
        ^ compiledQuery
×
33
]
×
34

35
{ #category : 'initialization' }
36
QueryCompilerPresenter >> initialExtent [
×
37

×
38
        ^ 350 @ 200
×
39
]
×
40

41
{ #category : 'initialization' }
42
QueryCompilerPresenter >> initialize [ 
×
43
        super initialize.
×
44
        codePresenter text: 'FQCollectScriptQuery script: [ :mooseEntity | "Your code here" ]'
×
45
]
×
46

47
{ #category : 'initialization' }
48
QueryCompilerPresenter >> initializeButtons [
×
NEW
49
        
×
50
        submitButton := self newButton.
×
51
        submitButton
×
52
                label: 'Submit';
×
NEW
53
                icon: (self iconNamed: #smallDoIt).
×
NEW
54
        closeButton := self newButton.
×
NEW
55
        closeButton
×
NEW
56
                label: 'Close';
×
NEW
57
                action: [ self owner dismiss ]
×
UNCOV
58
]
×
59

60
{ #category : 'initialization' }
61
QueryCompilerPresenter >> initializeCoder [
×
62

×
63
        codePresenter := self newCode.
×
64
        codePresenter
×
65
                withoutLineNumbers;
×
66
                beForScripting
×
67
]
×
68

69
{ #category : 'initialization' }
70
QueryCompilerPresenter >> initializeLayout [
×
71

×
72
        | tempLayout |
×
73
        tempLayout := SpBoxLayout newTopToBottom
×
74
                add: (SpBoxLayout newLeftToRight
×
NEW
75
                        add: closeButton expand: false;
×
76
                        addLast: submitButton expand: false;
×
77
                        yourself)
×
78
                expand: false;
×
79
                add: codePresenter;
×
80
                yourself.
×
81

×
82
        self layout: (SpBoxLayout newTopToBottom
×
83
                add: tempLayout
×
84
                withConstraints: [ :constraints | 
×
85
                        constraints
×
86
                                height: self initialExtent y;
×
87
                                width: self initialExtent x ];
×
88
                yourself)
×
89
]
×
90

91
{ #category : 'initialization' }
92
QueryCompilerPresenter >> initializePresenters [
×
93

×
94
        self initializeButtons.
×
95
        self initializeCoder.
×
96
        self initializeLayout
×
97
]
×
98

99
{ #category : 'accessing - model' }
100
QueryCompilerPresenter >> setModelBeforeInitialization: aModel [
×
101

×
102
        configuratorPresenter := aModel
×
103
]
×
104

105
{ #category : 'compiling' }
106
QueryCompilerPresenter >> submitQueryAction: aBlock [
×
107

×
108
        submitButton action: aBlock
×
109
]
×
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