@@ -37,27 +37,23 @@ impl PropertyHolder for MenuBarMessageHandler {
37
37
icon: Some ( "File" . into( ) ) ,
38
38
action: MenuEntry :: create_action( |_| DialogMessage :: RequestNewDocumentDialog . into( ) ) ,
39
39
shortcut: action_shortcut!( DialogMessageDiscriminant :: RequestNewDocumentDialog ) ,
40
- // shortcut: Some(vec![Key::KeyControl, Key::KeyN]),
41
40
children: MenuEntryGroups :: empty( ) ,
42
41
} ,
43
42
MenuEntry {
44
43
label: "Open…" . into( ) ,
45
44
shortcut: action_shortcut!( PortfolioMessageDiscriminant :: OpenDocument ) ,
46
- // shortcut: Some(vec![Key::KeyControl, Key::KeyO]),
47
45
action: MenuEntry :: create_action( |_| PortfolioMessage :: OpenDocument . into( ) ) ,
48
46
..MenuEntry :: default ( )
49
47
} ,
50
48
MenuEntry {
51
49
label: "Open Recent" . into( ) ,
52
- // shortcut: Some(vec![Key::KeyControl, Key::KeyShift, Key::KeyO]),
53
50
shortcut: None ,
54
51
action: MenuEntry :: no_action( ) ,
55
52
icon: None ,
56
53
children: MenuEntryGroups ( vec![
57
54
vec![
58
55
MenuEntry {
59
56
label: "Reopen Last Closed" . into( ) ,
60
- // shortcut: Some(vec![Key::KeyControl, Key::KeyShift, Key::KeyT]),
61
57
..MenuEntry :: default ( )
62
58
} ,
63
59
MenuEntry {
@@ -93,14 +89,12 @@ impl PropertyHolder for MenuBarMessageHandler {
93
89
vec![
94
90
MenuEntry {
95
91
label: "Close" . into( ) ,
96
- // shortcut: Some(vec![Key::KeyControl, Key::KeyW]),
97
92
shortcut: action_shortcut!( PortfolioMessageDiscriminant :: CloseActiveDocumentWithConfirmation ) ,
98
93
action: MenuEntry :: create_action( |_| PortfolioMessage :: CloseActiveDocumentWithConfirmation . into( ) ) ,
99
94
..MenuEntry :: default ( )
100
95
} ,
101
96
MenuEntry {
102
97
label: "Close All" . into( ) ,
103
- // shortcut: Some(vec![Key::KeyControl, Key::KeyAlt, Key::KeyW]),
104
98
shortcut: action_shortcut!( DialogMessageDiscriminant :: CloseAllDocumentsWithConfirmation ) ,
105
99
action: MenuEntry :: create_action( |_| DialogMessage :: CloseAllDocumentsWithConfirmation . into( ) ) ,
106
100
..MenuEntry :: default ( )
@@ -109,19 +103,16 @@ impl PropertyHolder for MenuBarMessageHandler {
109
103
vec![
110
104
MenuEntry {
111
105
label: "Save" . into( ) ,
112
- // shortcut: Some(vec![Key::KeyControl, Key::KeyS]),
113
106
shortcut: action_shortcut!( DocumentMessageDiscriminant :: SaveDocument ) ,
114
107
action: MenuEntry :: create_action( |_| DocumentMessage :: SaveDocument . into( ) ) ,
115
108
..MenuEntry :: default ( )
116
109
} ,
117
110
MenuEntry {
118
111
label: "Save As…" . into( ) ,
119
- // shortcut: Some(vec![Key::KeyControl, Key::KeyShift, Key::KeyS]),
120
112
..MenuEntry :: default ( )
121
113
} ,
122
114
MenuEntry {
123
115
label: "Save All" . into( ) ,
124
- // shortcut: Some(vec![Key::KeyControl, Key::KeyAlt, Key::KeyS]),
125
116
..MenuEntry :: default ( )
126
117
} ,
127
118
MenuEntry {
@@ -133,22 +124,19 @@ impl PropertyHolder for MenuBarMessageHandler {
133
124
vec![
134
125
MenuEntry {
135
126
label: "Import…" . into( ) ,
136
- // shortcut: Some(vec![Key::KeyControl, Key::KeyI]),
137
127
shortcut: action_shortcut!( PortfolioMessageDiscriminant :: Import ) ,
138
128
action: MenuEntry :: create_action( |_| PortfolioMessage :: Import . into( ) ) ,
139
129
..MenuEntry :: default ( )
140
130
} ,
141
131
MenuEntry {
142
132
label: "Export…" . into( ) ,
143
- // shortcut: Some(vec![Key::KeyControl, Key::KeyE]),
144
133
shortcut: action_shortcut!( DialogMessageDiscriminant :: RequestExportDialog ) ,
145
134
action: MenuEntry :: create_action( |_| DialogMessage :: RequestExportDialog . into( ) ) ,
146
135
..MenuEntry :: default ( )
147
136
} ,
148
137
] ,
149
138
vec![ MenuEntry {
150
139
label: "Quit" . into( ) ,
151
- // shortcut: Some(vec![Key::KeyControl, Key::KeyQ]),
152
140
..MenuEntry :: default ( )
153
141
} ] ,
154
142
] ) ,
@@ -159,14 +147,12 @@ impl PropertyHolder for MenuBarMessageHandler {
159
147
vec![
160
148
MenuEntry {
161
149
label: "Undo" . into( ) ,
162
- // shortcut: Some(vec![Key::KeyControl, Key::KeyZ]),
163
150
shortcut: action_shortcut!( DocumentMessageDiscriminant :: Undo ) ,
164
151
action: MenuEntry :: create_action( |_| DocumentMessage :: Undo . into( ) ) ,
165
152
..MenuEntry :: default ( )
166
153
} ,
167
154
MenuEntry {
168
155
label: "Redo" . into( ) ,
169
- // shortcut: Some(vec![Key::KeyControl, Key::KeyShift, Key::KeyZ]),
170
156
shortcut: action_shortcut!( DocumentMessageDiscriminant :: Redo ) ,
171
157
action: MenuEntry :: create_action( |_| DocumentMessage :: Redo . into( ) ) ,
172
158
..MenuEntry :: default ( )
@@ -175,23 +161,20 @@ impl PropertyHolder for MenuBarMessageHandler {
175
161
vec![
176
162
MenuEntry {
177
163
label: "Cut" . into( ) ,
178
- // shortcut: Some(vec![Key::KeyControl, Key::KeyX]),
179
164
shortcut: action_shortcut!( PortfolioMessageDiscriminant :: Cut ) ,
180
165
action: MenuEntry :: create_action( |_| PortfolioMessage :: Cut { clipboard: Clipboard :: Device } . into( ) ) ,
181
166
..MenuEntry :: default ( )
182
167
} ,
183
168
MenuEntry {
184
169
label: "Copy" . into( ) ,
185
170
icon: Some ( "Copy" . into( ) ) ,
186
- // shortcut: Some(vec![Key::KeyControl, Key::KeyC]),
187
171
shortcut: action_shortcut!( PortfolioMessageDiscriminant :: Copy ) ,
188
172
action: MenuEntry :: create_action( |_| PortfolioMessage :: Copy { clipboard: Clipboard :: Device } . into( ) ) ,
189
173
..MenuEntry :: default ( )
190
174
} ,
191
175
MenuEntry {
192
176
label: "Paste" . into( ) ,
193
177
icon: Some ( "Paste" . into( ) ) ,
194
- // shortcut: Some(vec![Key::KeyControl, Key::KeyV]),
195
178
shortcut: action_shortcut!( FrontendMessageDiscriminant :: TriggerPaste ) ,
196
179
action: MenuEntry :: create_action( |_| FrontendMessage :: TriggerPaste . into( ) ) ,
197
180
..MenuEntry :: default ( )
@@ -204,14 +187,12 @@ impl PropertyHolder for MenuBarMessageHandler {
204
187
children: MenuEntryGroups ( vec![ vec![
205
188
MenuEntry {
206
189
label: "Select All" . into( ) ,
207
- // shortcut: Some(vec![Key::KeyControl, Key::KeyA]),
208
190
shortcut: action_shortcut!( DocumentMessageDiscriminant :: SelectAllLayers ) ,
209
191
action: MenuEntry :: create_action( |_| DocumentMessage :: SelectAllLayers . into( ) ) ,
210
192
..MenuEntry :: default ( )
211
193
} ,
212
194
MenuEntry {
213
195
label: "Deselect All" . into( ) ,
214
- // shortcut: Some(vec![Key::KeyControl, Key::KeyAlt, Key::KeyA]),
215
196
shortcut: action_shortcut!( DocumentMessageDiscriminant :: DeselectAllLayers ) ,
216
197
action: MenuEntry :: create_action( |_| DocumentMessage :: DeselectAllLayers . into( ) ) ,
217
198
..MenuEntry :: default ( )
@@ -222,28 +203,24 @@ impl PropertyHolder for MenuBarMessageHandler {
222
203
children: MenuEntryGroups ( vec![ vec![
223
204
MenuEntry {
224
205
label: "Raise To Front" . into( ) ,
225
- // shortcut: Some(vec![Key::KeyControl, Key::KeyShift, Key::KeyLeftBracket]),
226
206
shortcut: action_shortcut!( DocumentMessageDiscriminant :: SelectedLayersRaiseToFront ) ,
227
207
action: MenuEntry :: create_action( |_| DocumentMessage :: SelectedLayersRaiseToFront . into( ) ) ,
228
208
..MenuEntry :: default ( )
229
209
} ,
230
210
MenuEntry {
231
211
label: "Raise" . into( ) ,
232
- // shortcut: Some(vec![Key::KeyControl, Key::KeyRightBracket]),
233
212
shortcut: action_shortcut!( DocumentMessageDiscriminant :: SelectedLayersRaise ) ,
234
213
action: MenuEntry :: create_action( |_| DocumentMessage :: SelectedLayersRaise . into( ) ) ,
235
214
..MenuEntry :: default ( )
236
215
} ,
237
216
MenuEntry {
238
217
label: "Lower" . into( ) ,
239
- // shortcut: Some(vec![Key::KeyControl, Key::KeyLeftBracket]),
240
218
shortcut: action_shortcut!( DocumentMessageDiscriminant :: SelectedLayersLower ) ,
241
219
action: MenuEntry :: create_action( |_| DocumentMessage :: SelectedLayersLower . into( ) ) ,
242
220
..MenuEntry :: default ( )
243
221
} ,
244
222
MenuEntry {
245
223
label: "Lower to Back" . into( ) ,
246
- // shortcut: Some(vec![Key::KeyControl, Key::KeyShift, Key::KeyRightBracket]),
247
224
shortcut: action_shortcut!( DocumentMessageDiscriminant :: SelectedLayersLowerToBack ) ,
248
225
action: MenuEntry :: create_action( |_| DocumentMessage :: SelectedLayersLowerToBack . into( ) ) ,
249
226
..MenuEntry :: default ( )
@@ -306,21 +283,18 @@ impl PropertyHolder for MenuBarMessageHandler {
306
283
MenuEntry {
307
284
label: "Off" . into( ) ,
308
285
// icon: Some("Checkmark".into()), // TODO: Find a way to set this icon on the active mode
309
- // shortcut: Some(vec![Key::KeyAlt, Key::Key0]),
310
286
shortcut: action_shortcut!( DebugMessageDiscriminant :: MessageOff ) ,
311
287
action: MenuEntry :: create_action( |_| DebugMessage :: MessageOff . into( ) ) ,
312
288
..MenuEntry :: default ( )
313
289
} ,
314
290
MenuEntry {
315
291
label: "Only Names" . into( ) ,
316
- // shortcut: Some(vec![Key::KeyAlt, Key::Key1]),
317
292
shortcut: action_shortcut!( DebugMessageDiscriminant :: MessageNames ) ,
318
293
action: MenuEntry :: create_action( |_| DebugMessage :: MessageNames . into( ) ) ,
319
294
..MenuEntry :: default ( )
320
295
} ,
321
296
MenuEntry {
322
297
label: "Full Contents" . into( ) ,
323
- // shortcut: Some(vec![Key::KeyAlt, Key::Key2]),
324
298
shortcut: action_shortcut!( DebugMessageDiscriminant :: MessageContents ) ,
325
299
action: MenuEntry :: create_action( |_| DebugMessage :: MessageContents . into( ) ) ,
326
300
..MenuEntry :: default ( )
@@ -331,14 +305,12 @@ impl PropertyHolder for MenuBarMessageHandler {
331
305
MenuEntry {
332
306
label: "Debug: Print Trace Logs" . into( ) ,
333
307
icon: Some ( if let log:: LevelFilter :: Trace = log:: max_level( ) { "CheckboxChecked" } else { "CheckboxUnchecked" } . into( ) ) ,
334
- // shortcut: Some(vec![Key::KeyAlt, Key::KeyT]),
335
308
shortcut: action_shortcut!( DebugMessageDiscriminant :: ToggleTraceLogs ) ,
336
309
action: MenuEntry :: create_action( |_| DebugMessage :: ToggleTraceLogs . into( ) ) ,
337
310
..MenuEntry :: default ( )
338
311
} ,
339
312
MenuEntry {
340
313
label: "Debug: Print Document" . into( ) ,
341
- // shortcut: Some(vec![Key::KeyAlt, Key::KeyP]),
342
314
shortcut: action_shortcut!( DocumentMessageDiscriminant :: DebugPrintDocument ) ,
343
315
action: MenuEntry :: create_action( |_| DocumentMessage :: DebugPrintDocument . into( ) ) ,
344
316
..MenuEntry :: default ( )
0 commit comments