110
|
1 |
"
|
|
2 |
jv:vdb - Visual / VM Debugger
|
|
3 |
Copyright (C) 2015-now Jan Vrany
|
|
4 |
|
|
5 |
This software is licensed under 'Creative Commons Attribution-NonCommercial 4.0 International License'
|
|
6 |
|
|
7 |
You may find a full license text in LICENSE.txt or at http://creativecommons.org/licenses/by-nc/4.0/
|
|
8 |
"
|
|
9 |
"{ Package: 'jv:vdb' }"
|
|
10 |
|
|
11 |
"{ NameSpace: Smalltalk }"
|
|
12 |
|
|
13 |
VDBAbstractPresenter subclass:#VDBRegisterPresenter
|
|
14 |
instanceVariableNames:'register'
|
|
15 |
classVariableNames:''
|
|
16 |
poolDictionaries:''
|
|
17 |
category:'VDB-Presentation'
|
|
18 |
!
|
|
19 |
|
|
20 |
!VDBRegisterPresenter class methodsFor:'documentation'!
|
|
21 |
|
|
22 |
copyright
|
|
23 |
"
|
|
24 |
jv:vdb - Visual / VM Debugger
|
|
25 |
Copyright (C) 2015-now Jan Vrany
|
|
26 |
|
|
27 |
This software is licensed under 'Creative Commons Attribution-NonCommercial 4.0 International License'
|
|
28 |
|
|
29 |
You may find a full license text in LICENSE.txt or at http://creativecommons.org/licenses/by-nc/4.0/
|
|
30 |
"
|
|
31 |
! !
|
|
32 |
|
|
33 |
!VDBRegisterPresenter class methodsFor:'menu specs'!
|
|
34 |
|
|
35 |
contextMenu
|
|
36 |
"This resource specification was automatically generated
|
|
37 |
by the MenuEditor of ST/X."
|
|
38 |
|
|
39 |
"Do not manually edit this!! If it is corrupted,
|
|
40 |
the MenuEditor may not be able to read the specification."
|
|
41 |
|
|
42 |
|
|
43 |
"
|
|
44 |
MenuEditor new openOnClass:VDBRegisterPresenter andSelector:#contextMenu
|
|
45 |
(Menu new fromLiteralArrayEncoding:(VDBRegisterPresenter contextMenu)) startUp
|
|
46 |
"
|
|
47 |
|
|
48 |
<resource: #menu>
|
|
49 |
|
|
50 |
^
|
|
51 |
#(Menu
|
|
52 |
(
|
|
53 |
(MenuItem
|
|
54 |
label: 'Copy Value'
|
|
55 |
itemValue: doCopyValue
|
|
56 |
isVisible: true
|
|
57 |
)
|
|
58 |
)
|
|
59 |
nil
|
|
60 |
nil
|
|
61 |
)
|
|
62 |
! !
|
|
63 |
|
|
64 |
!VDBRegisterPresenter methodsFor:'accessing'!
|
|
65 |
|
|
66 |
label
|
|
67 |
^ register name
|
|
68 |
|
|
69 |
"Created: / 27-02-2015 / 15:57:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
70 |
"Modified: / 27-09-2018 / 21:04:15 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
71 |
!
|
|
72 |
|
|
73 |
register
|
|
74 |
^ register
|
|
75 |
|
|
76 |
"Created: / 27-09-2018 / 20:39:09 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
77 |
!
|
|
78 |
|
|
79 |
subject
|
|
80 |
"Return an instance of GDB object that this presenter displays."
|
|
81 |
|
|
82 |
^ register
|
|
83 |
|
|
84 |
"Modified: / 05-02-2018 / 13:08:54 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
85 |
!
|
|
86 |
|
|
87 |
tooltip
|
|
88 |
^ self valueString
|
|
89 |
|
|
90 |
"Created: / 29-07-2018 / 21:35:25 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
91 |
!
|
|
92 |
|
|
93 |
value
|
|
94 |
^ register value
|
|
95 |
|
|
96 |
"Created: / 02-06-2017 / 07:32:38 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
97 |
"Modified: / 28-01-2018 / 22:49:54 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
98 |
!
|
|
99 |
|
|
100 |
valueString
|
|
101 |
^ register value
|
|
102 |
|
|
103 |
"Created: / 11-06-2017 / 23:25:28 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
104 |
"Modified: / 01-09-2018 / 00:55:24 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
105 |
! !
|
|
106 |
|
|
107 |
!VDBRegisterPresenter methodsFor:'initialization'!
|
|
108 |
|
|
109 |
setRegister:aGDBRegisterWithValue
|
|
110 |
register := aGDBRegisterWithValue
|
|
111 |
|
|
112 |
"Created: / 27-09-2018 / 20:38:00 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
113 |
! !
|
|
114 |
|
|
115 |
!VDBRegisterPresenter methodsFor:'menu actions'!
|
|
116 |
|
|
117 |
doCopyValue
|
|
118 |
self doCopy: register value.
|
|
119 |
|
|
120 |
"Created: / 16-01-2018 / 23:28:56 / jv"
|
|
121 |
"Modified: / 28-01-2018 / 22:55:14 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
122 |
! !
|
|
123 |
|
|
124 |
!VDBRegisterPresenter methodsFor:'protocol-queries'!
|
|
125 |
|
|
126 |
hasChildren
|
|
127 |
^ false
|
|
128 |
|
|
129 |
"Created: / 28-01-2018 / 22:49:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
130 |
"Modified: / 27-09-2018 / 20:38:58 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
131 |
! !
|
|
132 |
|
|
133 |
!VDBRegisterPresenter methodsFor:'testing'!
|
|
134 |
|
|
135 |
isRegisterPresenter
|
|
136 |
^ true
|
|
137 |
! !
|
|
138 |
|